Like this:
Note that DateDiff() is very literal in its calculations. If you use the Interval for Hours (h) it simply subtracts the two hours, so if StartTime is 12:00 (noon) and the EndTime is 13:59, then
Datediff("h",StartTime, EndTime)
will return 1 hour, because 13-12 = 1, although you're actually talking about 1 hour and 59 minutes. So what you have to do is use the Interval for Minutes (n) and then parse it into hours and fraction of hours.
So, the syntax of
Format(DateDiff("n", StartTime, EndTime) / 60,"0.00")
will return 1.98 hours.
Also note that using Format() to limit the returned time to two decimal places actually returns this as Text, and if you are going to do more math with the elapsed time you may have to convert it back to a Number, using something like CDbl(). I say 'maybe' because Access can be flexible in this area; sometimes if it looks like a Number it will be treated like a Number.
Linq ;0)>
The problem with making anything foolproof...is that fools are so darn ingenious!
All posts/responses based on Access 2003/2007