Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 3

Create a Edit Validate Rule and call it on Property Advanced Tab

Double doubleInput;

if (theValue != null)

if(theValue.contains("."))

String s = "" + theValue;

String[] result = s.split("\\.");

if (result[0].length()>6 || result[1].length()>2){

theProperty.addMessage("Sorry, there’s a problem with the data you’ve entered");

return false;

else if(theValue.length()>6)

{ -

theProperty.addMessage("Sorry, there’s a problem with the data you’ve entered");

return false;

else if(theValue != null)

try

doubleInput = new Double(theValue.toString());

catch (java.lang.NumberFormatException ex)


{

return false;

if (doubleInput.doubleValue() < 0)

theProperty.addMessage("Enter a non-negative number");

return false;

return true;

You might also like