A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

If Statement for a date



 
 
Thread Tools Display Modes
  #1  
Old June 17th, 2009, 04:55 PM posted to microsoft.public.excel.worksheet.functions
JLO
external usenet poster
 
Posts: 57
Default If Statement for a date

In cell A6 a date is entered. In another cell is a total number of items.
To get a total price for the items, I take Total Number of items and multiple
by the rate (0.335). The problem with that is the rate will increase
periodically from a specific date.

Is there an if statement or formula that will use A6 (date will be keyed in
the cell). Example the current rate for items is 0.335 on May 11, 2009 and
after. However any date previous to May 11, 2009 rate would be 0.324.

Thanks in advance.



  #2  
Old June 17th, 2009, 05:01 PM posted to microsoft.public.excel.worksheet.functions
Gary''s Student
external usenet poster
 
Posts: 7,584
Default If Statement for a date

=IF(A6DATEVALUE("5/11/2009"),0.324,0.335)

--
Gary''s Student - gsnu200857
  #3  
Old June 17th, 2009, 05:07 PM posted to microsoft.public.excel.worksheet.functions
Bernard Liengme[_2_]
external usenet poster
 
Posts: 1,027
Default If Statement for a date

This will return the rate based on your example
=IF(A6=DATE(2009,5,11),0.335,0.324)

We could do the multiplication with
=IF(A6=DATE(2009,5,11),0.335,0.324)*B6
where B6 is the cell with Total

Another way would be = B6*(0.324 + 0.011*(A6=DATE(2009,5,11))
Note that 0.011 is the increase in the rate after May 11.
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"jlo" wrote in message
...
In cell A6 a date is entered. In another cell is a total number of items.
To get a total price for the items, I take Total Number of items and
multiple
by the rate (0.335). The problem with that is the rate will increase
periodically from a specific date.

Is there an if statement or formula that will use A6 (date will be keyed
in
the cell). Example the current rate for items is 0.335 on May 11, 2009 and
after. However any date previous to May 11, 2009 rate would be 0.324.

Thanks in advance.




  #4  
Old June 17th, 2009, 06:01 PM posted to microsoft.public.excel.worksheet.functions
JLO
external usenet poster
 
Posts: 57
Default If Statement for a date

Thank you!

"Bernard Liengme" wrote:

This will return the rate based on your example
=IF(A6=DATE(2009,5,11),0.335,0.324)

We could do the multiplication with
=IF(A6=DATE(2009,5,11),0.335,0.324)*B6
where B6 is the cell with Total

Another way would be = B6*(0.324 + 0.011*(A6=DATE(2009,5,11))
Note that 0.011 is the increase in the rate after May 11.
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email


"jlo" wrote in message
...
In cell A6 a date is entered. In another cell is a total number of items.
To get a total price for the items, I take Total Number of items and
multiple
by the rate (0.335). The problem with that is the rate will increase
periodically from a specific date.

Is there an if statement or formula that will use A6 (date will be keyed
in
the cell). Example the current rate for items is 0.335 on May 11, 2009 and
after. However any date previous to May 11, 2009 rate would be 0.324.

Thanks in advance.





  #5  
Old June 17th, 2009, 06:02 PM posted to microsoft.public.excel.worksheet.functions
JLO
external usenet poster
 
Posts: 57
Default If Statement for a date

Thank you!

"Gary''s Student" wrote:

=IF(A6DATEVALUE("5/11/2009"),0.324,0.335)

--
Gary''s Student - gsnu200857

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 03:58 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.