ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Updated Function Question (https://www.excelbanter.com/excel-worksheet-functions/103895-updated-function-question.html)

cwilliams

Updated Function Question
 
I thought I would show an example of what exactly I am getting stuck on. I
am trying to put a rate in A5 based on the following

If A3 is 240 and A4 is 0 then look up the rates from Sheet 2 A1:B7 using
the age in A1 or If A3 is 600 and A4 is 0 then look up the rates from Sheet
2 C1:D7

Sheet 1
A B C
1 =ROUND((($I$1-J8)-185)/(365),0)
2
3 240
4 1
5 ??????
__________________________________________________ ___

Sheet 2
A B C D
240 600
1 1 200 1 500
2 20 300 20 600
3 30 852 30 585
4 40 856 40 893
5 50 159 50 984
6 60 188 60 848
7 70 519 70 561
8
9
10


Excelenator

Updated Function Question
 

If A3 is 240 and A4 is 0 then look up the rates from Sheet 2 A1:B7
using
the age in A1 or If A3 is 600 and A4 is 0 then look up the rates from
Sheet
2 C1:D7


=IF(AND(A3=240,A40),VLOOKUP(A1,Sheet2!A1:B7,2,FAL SE),IF(AND(A3=600,A40),VLOOKUP(A1,Sheet2!C1:D7,2, FALSE),0))


--
Excelenator


------------------------------------------------------------------------
Excelenator's Profile: http://www.excelforum.com/member.php...o&userid=36768
View this thread: http://www.excelforum.com/showthread...hreadid=569604



All times are GMT +1. The time now is 06:32 AM.

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