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.
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