Difference between two times

I

Igor G.

How to calculate difference between two times (same date)?
Example: First time = 6.30 Second time = 9.00
Difference must be: 2.30

Btw. can I copy time value from one textbox to second in Default Value
property, how?
Thanks!
 
D

Douglas J. Steele

The DateDiff function calculates time differences too, but it only will let
you choose a single unit. If you wanted that format, you'll have to do it
yourself as

DateDiff("n", [FirstTime], [SecondTime]) \ 60 & "." & Format(DateDiff("n",
[FirstTime], [SecondTime]) Mod 60, "00")
 
Top