Results 1 to 3 of 3
  1. #1
    anlimah is offline Novice
    Windows 8 Access 2010 64bit
    Join Date
    Jul 2014
    Location
    New York
    Posts
    6

    Calculating time data types

    How do I calculate elapsed time between start time and end time. I want my Length field to be populated automatically by calculating the elapsed time between start and end.

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    Have you looked into the DateDiff() function?

  3. #3
    Missinglinq's Avatar
    Missinglinq is offline VIP
    Windows 7 64bit Access 2007
    Join Date
    May 2012
    Location
    Richmond (Virginia, not North Yorkshire!)
    Posts
    3,018
    What kind of times are we speaking of? In what format do you want your results, i.e. minutes... hours and minutes... days, hours and minutes?

    Generally speaking, you use DateDiff(), as has been suggested, using the smallest unit of time you want to report. If you want hours and minutes you use minutes as the Interval in DateDiff() and then parse it out into hours and minutes.

    Linq ;0)>
    The problem with making anything foolproof...is that fools are so darn ingenious!

    All posts/responses based on Access 2003/2007

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 8
    Last Post: 08-24-2012, 01:54 AM
  2. Calculating Time
    By jlclark4 in forum Forms
    Replies: 0
    Last Post: 04-25-2011, 09:04 AM
  3. Replies: 12
    Last Post: 02-22-2011, 03:39 PM
  4. Memo Data Types
    By Joanne Searcy in forum Database Design
    Replies: 4
    Last Post: 12-28-2010, 08:04 PM
  5. Replies: 1
    Last Post: 08-04-2010, 04:38 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums