Unanswered: VB Code to compute the time difference
Greetings to all,
Is there a simple code that would compute for the time difference? Example from 10PM to 3AM. The result should be 5 hours. I have used DateDiff [Ex.DateDIff("h",10PM,3AM)], but the result is 19 hours...wherein it computes the time difference between 3AM to 10PM. I tried changing the time variants [Ex.DateDIff("h",3AM,10PM)], but the result is -19 hours.
Remember that dates in VB are really doubles cast as dates. 1.5 corresponds to 1 and 1/2 days after date 0, or 12 Noon on 31 Dec 1899.
Last edited by loquin; 09-26-06 at 17:52.
"Lisa, in this house, we obey the laws of thermodynamics!" - Homer Simpson
"I have my standards. They may be low, but I have them!" - Bette Middler
"It's a book about a Spanish guy named Manual. You should read it." - Dilbert