Maximum Value Allowed in Integer field

richelle_pivec
Mega Guru

I need to make a Minute field and an Hour field. I'd like to limit the Maximum Value the users are allowed to enter in the Minute integer field to 59. Any ideas on how to do that? The ask is for our users to manually enter how much time they actually spent completing the task (Hours and Minutes), so I can't use the Time Worked field.

Thanks,

Richelle

1 ACCEPTED SOLUTION

Mike Allen
Mega Sage

onChange of the minutes field:



if(newValue > 59){


alert('Minutes cannot be larger than 59.   Please adjust.');


return false;


}


View solution in original post

2 REPLIES 2

Mike Allen
Mega Sage

onChange of the minutes field:



if(newValue > 59){


alert('Minutes cannot be larger than 59.   Please adjust.');


return false;


}


Perfect! The client script worked just like I needed it to.



Thanks,



Richelle