Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default If Function Value if true = Date +30days

Hello,

Question about IF function.
A1 = date of order;
B2= either "rejected" or "approved"
C3= +30 days if A2=rejected or +60 days if A2=approved

I tried to creat function for this:

A3 = IF(B2="rejected",A2+30,A2+60)

But the function is not returning a date. For example if

A1= 2/2/1990
B1=rejected
C1 = 32936

I don't know why its not working. Do I need to format it to return a date
somehow?

Thanks!

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default If Function Value if true = Date +30days

Try formatting the cell as DATE

In Excel dates are really just numbers that are formatted to look like
dates. The numbers are the number of days since a predefined date. That
predefined date is Jan 1 1900. So, the result you got is the 32936th day
since Jan 1 1900, or, when formatted as DATE, 4/3/1990.

Biff

"TypeType" wrote in message
...
Hello,

Question about IF function.
A1 = date of order;
B2= either "rejected" or "approved"
C3= +30 days if A2=rejected or +60 days if A2=approved

I tried to creat function for this:

A3 = IF(B2="rejected",A2+30,A2+60)

But the function is not returning a date. For example if

A1= 2/2/1990
B1=rejected
C1 = 32936

I don't know why its not working. Do I need to format it to return a date
somehow?

Thanks!



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 857
Default If Function Value if true = Date +30days

Yes, you need to format it as a date.

Format-Cells, then select Date.


"TypeType" wrote:

Hello,

Question about IF function.
A1 = date of order;
B2= either "rejected" or "approved"
C3= +30 days if A2=rejected or +60 days if A2=approved

I tried to creat function for this:

A3 = IF(B2="rejected",A2+30,A2+60)

But the function is not returning a date. For example if

A1= 2/2/1990
B1=rejected
C1 = 32936

I don't know why its not working. Do I need to format it to return a date
somehow?

Thanks!

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Need true or false if a date falls between a date range dustin Excel Worksheet Functions 3 December 9th 06 02:01 AM
IF Function doesn't recognize TRUE AMY Z. Excel Worksheet Functions 6 October 24th 06 11:28 PM
Function to return True/False if all are validated as True by ISNU Tetsuya Oguma Excel Worksheet Functions 2 March 15th 06 10:28 AM
How to get date entered recording first time condition is true? Dan Morton Excel Discussion (Misc queries) 5 September 8th 05 12:19 AM
If Function true value in Red donnaK Excel Worksheet Functions 4 December 16th 04 06:55 PM


All times are GMT +1. The time now is 07:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"