Subforms - Date/Time

  • Thread starter Thread starter Beeyen
  • Start date Start date
B

Beeyen

I have a situation as follows below; I am having problems mostly with coding
the conversion for the date and time to total the minute. What would suggest
as the event procedure? Or is there an easier way to accomplish the results I
am trying to achieve?

Production Completed [Date/Time field] [Check Box = Yes] Selecting the
Check Box populates the current date and time

Total Time to Complete [Total Minutes field (auto-populates)] A start time
field which has the date and time called [Assigned Time] located in another
sub-form tab, this minus the Production Completed [Date/Time] field above
equals the [Minutes] field.

So; Production Completed (in Date/Time) (minus) Assigned Time (in Date/Time)
(equals) Total Time to Complete (in minutes)

Your experience and any assistance you can provide would be greatly
appreciated.


Thanks
 
Total Time to Complete [Total Minutes field (auto-populates)] A start time
field which has the date and time called [Assigned Time] located in another
sub-form tab, this minus the Production Completed [Date/Time] field above
equals the [Minutes] field.

So; Production Completed (in Date/Time) (minus) Assigned Time (in Date/Time)
(equals) Total Time to Complete (in minutes)

DateDiff("n", [Assigned Time], [Production Completed])

A Date/Time field (regardless of format) is stored as a number, a count of
days and fractions of a day (times, e.g. 0.25 = 6:00am). The DateDiff function
lets you calculate time elapsed in any desired unit from seconds to years.
 
Excellent! and Thank you for the quick response.

Good Day

John W. Vinson said:
Total Time to Complete [Total Minutes field (auto-populates)] A start time
field which has the date and time called [Assigned Time] located in another
sub-form tab, this minus the Production Completed [Date/Time] field above
equals the [Minutes] field.

So; Production Completed (in Date/Time) (minus) Assigned Time (in Date/Time)
(equals) Total Time to Complete (in minutes)

DateDiff("n", [Assigned Time], [Production Completed])

A Date/Time field (regardless of format) is stored as a number, a count of
days and fractions of a day (times, e.g. 0.25 = 6:00am). The DateDiff function
lets you calculate time elapsed in any desired unit from seconds to years.
 
Back
Top