public boolean validate()
{
boolean isValid = true;
/* if (!fromDate)
{
isValid = checkFailed("From Date should be entered");
}
if (!toDate)
{
isValid = checkFailed("To Date should be entered");
}
if (isValid && (fromDate > toDate))
{
isValid = checkFailed(strfmt("From Date should be less than or equal to To Date", date2StrUsr(fromDate, DateFlags::FormatAll), date2StrUsr(toDate, DateFlags::FormatAll)));
}
if (!Name)
{
isValid = checkFailed("Name should be entered");
}
*/
return isValid;
}
for validation u have to write this code in contract class class delaration method
contractclassname implements SysOperationValidatable
{
boolean isValid = true;
/* if (!fromDate)
{
isValid = checkFailed("From Date should be entered");
}
if (!toDate)
{
isValid = checkFailed("To Date should be entered");
}
if (isValid && (fromDate > toDate))
{
isValid = checkFailed(strfmt("From Date should be less than or equal to To Date", date2StrUsr(fromDate, DateFlags::FormatAll), date2StrUsr(toDate, DateFlags::FormatAll)));
}
if (!Name)
{
isValid = checkFailed("Name should be entered");
}
*/
return isValid;
}
for validation u have to write this code in contract class class delaration method
contractclassname implements SysOperationValidatable
No comments:
Post a Comment