Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
function on date
=TODAY() This is in K3 and formated to show day so it shows 13
=IF(("K3=13")123,"") This is in C 26 results #Value Should be 123 or "" Don't see what I have missed. I've run my gamet Anyone Thanks |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
function on date
Formatting K3 does not affect the value excel uses in functions.
In C26 try... =IF(DAY(K3)=13,123,"") Ken Johnson |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
function on date
=TODAY() This is in K3 and formated to show day so it shows 13
The formatted *display* value is not the true underlying value of the cell. If TODAY() is 2/13/2009 the *true underlying value* of the cell is 39857. However, that is not why your formula is returning an error. It should be written like this: =IF(K3=13,123,"") However, this will *always* return "" (blank) because K3 will *never* equal 13. If you want K3 to display the day of the month use this: =DAY(NOW()) Format as General or Number -- Biff Microsoft Excel MVP "Curt" wrote in message ... =TODAY() This is in K3 and formated to show day so it shows 13 =IF(("K3=13")123,"") This is in C 26 results #Value Should be 123 or "" Don't see what I have missed. I've run my gamet Anyone Thanks |
#4
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
function on date
On Fri, 13 Feb 2009 18:48:00 -0800, Curt
wrote: =TODAY() This is in K3 and formated to show day so it shows 13 =IF(("K3=13")123,"") This is in C 26 results #Value Should be 123 or "" Don't see what I have missed. I've run my gamet Anyone Thanks 1. It would have been helpful if you had copied your formula into this post instead of typing it. As written, your formula is invalid for several reasons. It is missing a comma between the logical test, and the value_if_true segment, assuming that is what you want to do. 2. "K3=13" is a string. It is a string because it is enclosed with quotation marks. The first argument of an IF function needs to be a logical test, something that evaluates to TRUE or FALSE. A string does neither. If your purpose is to determine if the contents of K3 is 13, that would be properly expressed as: =IF(K3=13,value_if_true,value_if_false) In your representation above, you have parentheses around the logical test. Although it doesn't hurt anything, what was your reason for using them? They seem to be superfluous. 3. You wrote that K3 is **formatted** to show the day so it shows 13. But you are testing the *contents* of K3. Formatting a cell only changes what it "shows". It does not change the *contents*. The full date is still being returned by the TODAY() function. There are two solutions. 1. Change your formula to read =if(day(k3)=13,123,"") 2. Correct your formula to read =if(k3=13,123,"") and also change K3 to be =day(today()) (and you should also format K3 to General). --ron |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Date function in ACCRINTM requires date format not available | Excel Worksheet Functions | |||
MAX figure within a date range as a function of today()'s date | Excel Worksheet Functions | |||
SUMIF within date range as a function of today()'s date | Excel Worksheet Functions | |||
Date Function formula that will return the date of a specific week | Excel Worksheet Functions | |||
Calculating days between current date and a date in future NETWORKDAYS() function | Excel Worksheet Functions |