Results 1 to 4 of 4

Change time range for functions

Threaded View

  1. #4
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Change time range for functions

    In the example, A1 is the "in" hour and B1 the "out" hour.
    As you know, XL stores dates as numbers, 1 day being 1. So one hour is 1/24 day

    What the formula does is
    1 Evaluate the diff B1 and A1 ( which is a number smaller then one provided the patient doesn't stay in bed more than 24 hrs)
    2. Add 1 if the "out" hour is smaller than the "in" hour, thus taking care of the fact XL does not allow negative times or durations

    Maybe post a sample of your data as example

    Instead of the formula provided you can also use =mod(b1-a1,1)
    Last edited by arthurbr; 02-08-2011 at 04:49 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1