if( ri!valueType_txt = "Ratio", if( and( like(ri!inputValue_txt, "*:*"), isnull( stripwith(ri!inputValue_txt, "1234567890:.") ), not( isnull(stripwith(ri!inputValue_txt, ":.")) ), left(ri!inputValue_txt) <> ":", right(ri!inputValue_txt) <> ":" ), "", cons!CR_APP_COV_THRESHOLD_VALIDATION_MSG[1] ), if( ri!valueType_txt = "Ratio:1", if( and( like(ri!inputValue_txt, "*:1"), isnull( stripwith(ri!inputValue_txt, "1234567890:.") ), not( isnull(stripwith(ri!inputValue_txt, ":.")) ), left(ri!inputValue_txt) <> ":", right(ri!inputValue_txt) <> ":" ), "", "Value is not in the format of m:1." ), if( ri!valueType_txt = cons!CR_APP_FIN_COV_VALUE_TYPES[3], if( and( len( stripwith(ri!inputValue_txt, "0123456789.") ) = 0, len(cleanwith(ri!inputValue_txt, ".")) < 2 ), if( and( len( cleanwith(ri!inputValue_txt, "0123456789") ) < 15 ), "", cons!CR_APP_COV_THRESHOLD_VALIDATION_MSG[3] ), cons!CR_APP_COV_THRESHOLD_VALIDATION_MSG[4] ), if( ri!valueType_txt = cons!CR_APP_FIN_COV_VALUE_TYPES[4], if( and( len( stripwith(ri!inputValue_txt, "0123456789.%") ) = 0, len(cleanwith(ri!inputValue_txt, ".")) < 2 ), "", cons!CR_APP_COV_THRESHOLD_VALIDATION_MSG[4] ), "" ) ) ) )
Hi Everyone, I am looking for a solution related to when valueType= "Ratio:1", then the upto 3 decimals on left side:1 ,need to restrict values which are entered more than 4 decimals in left only, How Can I do that,Can anyone help to do that?
Discussion posts and replies are publicly visible
I have a hard time understanding your explanation. Can you help me?
ok, So we have value type in ui has ratio:1 type that means user can enter value has 5.6678435.1 format ,but instead of entering more that 3 decimals ,we need to restrict up to 3 decimals only. I hope now this sentence understandable.
JS0001 said: 5.6678435.1 format
You mean 5.6678435:1
Hm ... didi you consider to use two fields for this? That would make the validation much easier and the user would not have to enter the colon.
Then, why not just round the entered value to three decimals?