i have created a Report, which is accessed from a dailog. which has integer field. how to check if the user has inserted a integer value or not, and give a warning message if he has not inserted an integer value. Am using AX2009
By default Dialogbox can consider the type of datatype. It cant accept string value in integer datatype field, It will give warning Automatically.
yea it gives… but i want to give a custom warning message for it… how can i achieve this.
it gives a pop up box… but i want a warning message.
Try this code in getFromDialog method.
boolean getFromDialog()
{
boolean ret;
;
_IntegerField = dlgField.value();
if(isInteger (_IntegerField))
{
ret = true;
}
Else
checkfailed(“Enter an Integer Value”);
return ret;
}
it does not work… but thanks for the help. i dint know about isInteger().
what was the problem with isInteger() function
if(isInteger(‘1.23’))
{
info(‘integer’);
}
Else
warning(“Enter an Integer Value”);//prompts warning message Enter an Integer Value