How should the formula read to check the TIME value of a certain cell for 12:00 PM?
If the TIME in the referenced cell is 12:00 PM...return NOON.
Here is what I have...and it doesn't work:
Please Login or Register to view this content.
How should the formula read to check the TIME value of a certain cell for 12:00 PM?
If the TIME in the referenced cell is 12:00 PM...return NOON.
Here is what I have...and it doesn't work:
Please Login or Register to view this content.
Last edited by HuskerBronco; 12-14-2008 at 06:19 PM.
That formula should work assuming Data!C12 contains just a time.
What's in C12, is it generated by a formula?
When I select the cell, this is what shows in the formula bar:What's in C12, is it generated by a formula?
The cell (C12) is TIME formatted, and the time entered comes from a drop-down list containing all times from 10:00 AM to 11:00 PM...incremented every 30 minutes.Please Login or Register to view this content.
The NAMED RANGE that the drop-down list comes from DID contain formulas...but I overwrote them with TIME values...and it still didn't work.
Format C12 as General and what do you see?
Entia non sunt multiplicanda sine necessitate
Excel sometimes behaves oddly when you increment times like that. I can't replicate the specific problem, though. What formula did you use to increase the time by 30 minutes?
Try using this version
=IF(TEXT(DATA!C12,"h:mm")="12:00","NOON",DATA!C12)
I just tried your formula and it worked for me. You said that "... it doesn't work ..." so what do you see instead of "NOON"? Also, if the time in C12 is supposedly 12:00:00 and you temporarily change the cell format to numeric is it 0.50000? If you change the formula to:
what does it display?Please Login or Register to view this content.
Ben Van Johnson
In the formula bar... 0.499999998666667Format C12 as General and what do you see?
And...it still says 12:00 PM in the target cell. (Not NOON)
Well -- that's not noon.
You could use DLL's suggestion, or fix the drop-down ...
In cell A1 of the NAMED RANGE "Times" I have 10:00 AM.What formula did you use to increase the time by 30 minutes?
Cell A2 contains the following formula:
The formula in A2 was then copied down enough cells to display 11:00 PM as the last time.Please Login or Register to view this content.
I haven't got a clue why this wasn't giving me a .5 for 12:00 PM (but rather...0.499999998666667).
This formula, on the other hand, worked perfectly....!!!Try using this version
=IF(TEXT(DATA!C12,"h:mm")="12:00","NOON",DATA!C12)
Thank you, so much for your help.
Because repeating decimals can't be exactly represented.I haven't got a clue why this wasn't giving me a .5 for 12:00 PM
So...that was my problem the whole time.Better to use =A1+"0:30" or =A1+TIME(0,30,0)
I switched the formula in Cell A2 to =A1+TIME(0,30,0)...and copied it down.
Then I used the new drop-down menu to enter the time in each cell from C1 down.
Finally, I reverted to my original formula in the target cells...and it worked exactly as I needed it to!!!
Didn't think this would be so difficult...
Thanks for all of your help...guys.
Last edited by HuskerBronco; 12-15-2008 at 08:32 AM. Reason: Typo
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks