Page 182 - Excel Timesaving Techniques for Dummies
P. 182
34_574272 ch30.qxd 10/1/04 10:50 PM Page 167
167
When Your Time Is Up
To convert decimal numbers like this that represent
the fraction of an entire day into the number of
hours that have elapsed, you simply multiply these
results by 24. Figure 30-6 shows you the worksheet
after editing the original formula in F2 to do just this:
=ROUND((E2-D2)*24,2)
Figure 30-6 shows the worksheet after copying this
edited formula to the rest of the column in range
F3:F13 and formatting all the results in the Hours
Worked column with the Accounting number format
with two decimal places.
• Figure 30-5: Calculating the difference between a stop
time and a start time.
The way to deal with this is simply to apply another,
more appropriate number format to the results.
However, if you apply the General format to the
result of such time arithmetic, you find that Excel
then displays the differences as decimal values rep-
resenting what fraction of a day (that is, a 24-hour
period) that difference represents. If, for example,
you apply the General format to cell F2 containing
9:00 AM as the difference between the stop time of
4:30 PM in cell E2 and the start time of 7:30 AM in
• Figure 30-6: Hours Worked column after converting the
cell D2, you end up with this decimal number:
calculated elapsed times to hours.
0.375