Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
vb for nested if with more than 7 statements
Hi,
I have a nested if with 9 statements, which won't work. I've looked this up and read i need to convert to code. Can i please have some help? I know VB for access, but not really done much with excel. I have 9 different car types, and each one has a different value. I just want it to say, after a cell in range B2:B1000 is changed, if that cell = car type 1, the cell in C2:C2000 changes to the value £100 and if it changes to car type 2, the cell in column C changes to value £200 etc..... Thanks, Kirstie |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
vb for nested if with more than 7 statements
Use a vlookup instead of an if.
Put your list of cars and prices on another sheet. Then, in the cell that needs to change - type: =vlookup( You can then use the fx button to guide you through using vlookups. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
vb for nested if with more than 7 statements
Take a look at this:
http://www.contextures.com/xlFunctions02.html If you feel brave look he http://www.mvps.org/dmcritchie/excel/vlookup.htm Regards, Ryan--- -- RyGuy "Stuart Bray" wrote: Use a vlookup instead of an if. Put your list of cars and prices on another sheet. Then, in the cell that needs to change - type: =vlookup( You can then use the fx button to guide you through using vlookups. |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
vb for nested if with more than 7 statements
Is me, on another computer in another office!
Got it working with Vlookup (great wee function) Thanks for your help. Kirstie Adam "Kirstie Adam" (nospam) wrote in message ... Hi, I have a nested if with 9 statements, which won't work. I've looked this up and read i need to convert to code. Can i please have some help? I know VB for access, but not really done much with excel. I have 9 different car types, and each one has a different value. I just want it to say, after a cell in range B2:B1000 is changed, if that cell = car type 1, the cell in C2:C2000 changes to the value £100 and if it changes to car type 2, the cell in column C changes to value £200 etc..... Thanks, Kirstie |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
vb for nested if with more than 7 statements
took me a while to get it, but worked great, thanks
k "Stuart Bray" wrote in message ... Use a vlookup instead of an if. Put your list of cars and prices on another sheet. Then, in the cell that needs to change - type: =vlookup( You can then use the fx button to guide you through using vlookups. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Nested If Statements | Excel Worksheet Functions | |||
Too Many Nested IF Statements! | Excel Worksheet Functions | |||
Help with nested if/or statements | Excel Discussion (Misc queries) | |||
Nested IF statements | Excel Worksheet Functions | |||
Nested IF statements | Excel Discussion (Misc queries) |