I am trying to substring for Min and Max experience, but it is not working properly

I am trying to Min experience and max experience value in decision, it working fine when i am adding value in decimal eg min exp =12.11 and max exp = 13.11  but when i am trying add min and max experience in number eg min exp = 12 and max exp 4  it is throw error message    Please anyone can guide me    Thanks in advance 
2 answers

Try using the ParseDecimal action from the Decimal Tools module in the Marketplace to convert from a String to a Decimal.

It supports more flexible parsing than the built-in Mendix ParseDecimal method. If the String is not a valid decimal then an error will be thrown, so be sure to put error handling on the ParseDecimal action.

Hope this helps.


Hi Jayanthi,


As per my understanding, you are trying to check whether the entered number is decimal or not. 


I hope ,You have declared the attributes as a decimal, then in that case. 

Value stored in this attribute will always have decimal dot(.) even if user enters 12 or 12.15.


if you want to check whether it is decimal or not. Declare the attribute as String, get the value from user.


if user wants to give 12, then they will enter only 12 . 

if user wants to give 12.15, then they will enter only 12.15


then in your decision check for decimal like this


contains($stringVariable,’.’)  – This condition will give false for 12 whereas it will give true from 12.15