calculate time - InfoPath Dev
in

InfoPath Dev

calculate time

Last post 10-12-2011 07:23 PM by MoBayTech. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 10-12-2011 04:28 PM

    calculate time

    I have two drop down fields data type time named TimeIn and TimeOut and another text box field named hours that I want to show the results of the time a user worked.

    Example:

    TimeIn = 9:00 AM TimeOut = 5:00 PM then hours = 8

    I can't figure how in infopath to calculate the hours field, any ideas on how to solve this issue?

     

    Timesheet 1Timesheet 2

  • 10-12-2011 07:23 PM In reply to

    solved my issue with http://blogs.msdn.com/b/infopath/archive/2007/02/21/calculating-elapsed-time-without-code.aspx

    (((substring-before(endTime, ":") * 60) + substring-before(substring-after(endTime, ":"), ":")) - ((substring-before(startTime, ":") * 60) + substring-before(substring-after(startTime, ":"), ":"))) / 60
Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.