ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Time formula (difference of predicted and actual time) (https://www.excelbanter.com/excel-discussion-misc-queries/202547-time-formula-difference-predicted-actual-time.html)

Deb

Time formula (difference of predicted and actual time)
 
I have a time formula in my spreedsheet. It is to calculate the difference
in a predicted time with the actual time. Time is entered as text eg. 14:00.
My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. However I cannot get a result for the time if the actual
time is later than the predicted time. I need the result to be -h,mm. If
you can help me accomplish this I would really appriceate it. Thank you

Bob Phillips[_3_]

Time formula (difference of predicted and actual time)
 
=IF(H4A4,"-","")&TEXT(MOD(A4-H4,1),"H:MM")

--
__________________________________
HTH

Bob

"deb" wrote in message
...
I have a time formula in my spreedsheet. It is to calculate the difference
in a predicted time with the actual time. Time is entered as text eg.
14:00.
My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. However I cannot get a result for the time if the actual
time is later than the predicted time. I need the result to be -h,mm. If
you can help me accomplish this I would really appriceate it. Thank you




muddan madhu

Time formula (difference of predicted and actual time)
 
check it here

http://www.j-walk.com/ss/excel/usertips/tip051.htm




On Sep 15, 12:00*pm, deb wrote:
I have a time formula in my spreedsheet. *It is to calculate the difference
in a predicted time with the actual time. Time is entered as text eg. 14:00. *
*My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. *However I cannot get a result for the time if the actual
time is later than the predicted time. *I need the result to be -h,mm. *If
you can help me accomplish this I would really appriceate it. *Thank you



David Biddulph[_2_]

Time formula (difference of predicted and actual time)
 
If the answer should be -3 hours, your formula gives -21 hours, Bob.

Perhaps try
=IF(H4A4,"-","")&TEXT(ABS(A4-H4),"H:MM")
--
David Biddulph

"Bob Phillips" wrote in message
...
=IF(H4A4,"-","")&TEXT(MOD(A4-H4,1),"H:MM")

--
__________________________________
HTH

Bob

"deb" wrote in message
...
I have a time formula in my spreedsheet. It is to calculate the
difference
in a predicted time with the actual time. Time is entered as text eg.
14:00.
My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. However I cannot get a result for the time if the actual
time is later than the predicted time. I need the result to be -h,mm.
If
you can help me accomplish this I would really appriceate it. Thank you






Deb

Time formula (difference of predicted and actual time)
 
Thanks David, this works great for the late times but now it does not show
early times properly do you know what to do so that it will work either way.
Thanks again

"David Biddulph" wrote:

If the answer should be -3 hours, your formula gives -21 hours, Bob.

Perhaps try
=IF(H4A4,"-","")&TEXT(ABS(A4-H4),"H:MM")
--
David Biddulph

"Bob Phillips" wrote in message
...
=IF(H4A4,"-","")&TEXT(MOD(A4-H4,1),"H:MM")

--
__________________________________
HTH

Bob

"deb" wrote in message
...
I have a time formula in my spreedsheet. It is to calculate the
difference
in a predicted time with the actual time. Time is entered as text eg.
14:00.
My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. However I cannot get a result for the time if the actual
time is later than the predicted time. I need the result to be -h,mm.
If
you can help me accomplish this I would really appriceate it. Thank you







Deb

Time formula (difference of predicted and actual time)
 
Thank you. Very simple solution

"muddan madhu" wrote:

check it here

http://www.j-walk.com/ss/excel/usertips/tip051.htm




On Sep 15, 12:00 pm, deb wrote:
I have a time formula in my spreedsheet. It is to calculate the difference
in a predicted time with the actual time. Time is entered as text eg. 14:00.
My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. However I cannot get a result for the time if the actual
time is later than the predicted time. I need the result to be -h,mm. If
you can help me accomplish this I would really appriceate it. Thank you




David Biddulph[_2_]

Time formula (difference of predicted and actual time)
 
In what situations is it not working?
Please tell us what formula you've used, what numbers were in the cells
feeding into the formula, what result you got, and what result you expected.
--
David Biddulph

"deb" wrote in message
...
Thanks David, this works great for the late times but now it does not show
early times properly do you know what to do so that it will work either
way.
Thanks again

"David Biddulph" wrote:

If the answer should be -3 hours, your formula gives -21 hours, Bob.

Perhaps try
=IF(H4A4,"-","")&TEXT(ABS(A4-H4),"H:MM")
--
David Biddulph

"Bob Phillips" wrote in message
...
=IF(H4A4,"-","")&TEXT(MOD(A4-H4,1),"H:MM")

--
__________________________________
HTH

Bob

"deb" wrote in message
...
I have a time formula in my spreedsheet. It is to calculate the
difference
in a predicted time with the actual time. Time is entered as text eg.
14:00.
My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. However I cannot get a result for the time if the
actual
time is later than the predicted time. I need the result to be -h,mm.
If
you can help me accomplish this I would really appriceate it. Thank
you








Deb

Time formula (difference of predicted and actual time)
 
I am so sorry my mistake. I'm not sure what I did wrong, but I reworked it
and the formula you provided worked perfect. Thank you so much

"David Biddulph" wrote:

In what situations is it not working?
Please tell us what formula you've used, what numbers were in the cells
feeding into the formula, what result you got, and what result you expected.
--
David Biddulph

"deb" wrote in message
...
Thanks David, this works great for the late times but now it does not show
early times properly do you know what to do so that it will work either
way.
Thanks again

"David Biddulph" wrote:

If the answer should be -3 hours, your formula gives -21 hours, Bob.

Perhaps try
=IF(H4A4,"-","")&TEXT(ABS(A4-H4),"H:MM")
--
David Biddulph

"Bob Phillips" wrote in message
...
=IF(H4A4,"-","")&TEXT(MOD(A4-H4,1),"H:MM")

--
__________________________________
HTH

Bob

"deb" wrote in message
...
I have a time formula in my spreedsheet. It is to calculate the
difference
in a predicted time with the actual time. Time is entered as text eg.
14:00.
My formula is
=TEXT(A4-H4,"H:MM") OR
=TEXT(predicted time - actual time, "H:MM")

The formula works great if the actual time is prior to or equal to the
predicted time. However I cannot get a result for the time if the
actual
time is later than the predicted time. I need the result to be -h,mm.
If
you can help me accomplish this I would really appriceate it. Thank
you










All times are GMT +1. The time now is 11:01 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com