Time sheets


ive seen many people inquiring how create time sheets allow user enter in time, out time, , subtract out time in time figure total hours worked. suggestion use time2num function, little other information given people on how use correctly combined setting need made other objects time sheet function way want.

ive saved calculation section of time sheet created , saved in .tds livedesigner 7 format, having problems coding involved in process can download form , click on individual objects see code used form work correctly. implemented if/then function field has time2num function not display until both in/out fields have values. otherwise display 0" in it's field regardless of being entered yet.

this form not without few quirks inherent in time2num function. time entered must in double digit hh:mm:ss format. if enter 8:00:00 receive validation error message must enter time hh:mm:ss, correct entry 08:00:00. tried time2num function work format h:mm enter 8:00 am, either im not setting object value and/or formula correctly, or function operates in military time , requires value seconds.

however display pattern fields set display military time standard time format. entry of 08:30:00 display 8:30 or 17:00:00 display 5:00 pm. type of configuration if time needs changed must re-enter time entire field in military time again time2num function operate properly. after enter 08:30:00 field display 8:30 am. if select 8 , change 8 9, total hours wrong. need select entire text 8:30 , enter 09:30:00.

fyi: large problem came across happend after entered few numbers, saved form, closed it, , reopened it. time2num calculation fields displayed "0". solution problem remove data pattern value of "hh:mm:ss" in/out objects binding properties. when form reopened after saved retains it's calculations.

you can download form here: http://www.industrialimaginations.com/items/timesheet.tds

if can figure out how make time2num function using h:mm format please let me know. make form simpler use.

i realized have error in calculation on form. in last total hours columns on right integer needs changed - +. current formula subtract absent time total rather add , results in incorrect total time.


More discussions in LiveCycle pre-ES (6.x and 7.x) discussions


adobe

Comments