Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
I'm trying to set up a formula that will check the value of a cell, then
based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
=INDEX(A3:A5,C2)
"Aaargh" wrote: I'm trying to set up a formula that will check the value of a cell, then based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
In Cell G2 type =IF(C2=1,A3,IF(C2=2,A4,IF(C2=3,A5,IF(C2=4,A6,""))) )
This should give you the values you've entered in A3, A4, A5 etc in cell G2 depending what value is in C2, Best regards, Gareth "Aaargh" wrote: I'm trying to set up a formula that will check the value of a cell, then based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#4
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
There is a debate between which is better OFFSET/INDEX, but you could also do:
=OFFSET(A2,C1) Offset may give you more control if you want to control both row and column destination. -- Best Regards, Luke M *Remember to click "yes" if this post helped you!* "Aaargh" wrote: I'm trying to set up a formula that will check the value of a cell, then based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#5
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
another one,
try this in g2 =CHOOSE(C2,A3,A4,A5) -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Aaargh" wrote: I'm trying to set up a formula that will check the value of a cell, then based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#6
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
OFFSET needs more parameters than that, or at least a place for them.
Try =OFFSET(A2,C1,) [with the extra comma.] -- David Biddulph "Luke M" wrote in message ... There is a debate between which is better OFFSET/INDEX, but you could also do: =OFFSET(A2,C1) Offset may give you more control if you want to control both row and column destination. -- Best Regards, Luke M *Remember to click "yes" if this post helped you!* "Aaargh" wrote: I'm trying to set up a formula that will check the value of a cell, then based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#7
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
The CHOOSE function worked well for one set when it dealt with sequential
values but didn't work for a set that has non-sequential values. The data is also located in non-sequential cell locations. I don't know if this helps clarify the situation. But thank you so much for the CHOOSE suggestion. At least I got one set completed. "Aaargh" wrote: I'm trying to set up a formula that will check the value of a cell, then based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#8
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
The nested IF functions worked the best... this is what I ended up with.
=IF(E2=4,Sewer!$K$4,IF(E2=99,Sewer!$K$9,IF(E2=12,S ewer!$K$7,IF(E2=5,Sewer!$K$5,IF(E2=1,Sewer!$K$2,IF (E2=6,Sewer!$K$6,IF(E2=12,Sewer!$K$7,IF(E2=17,Sewe r!$K$8)))))))) "Aaargh" wrote: The CHOOSE function worked well for one set when it dealt with sequential values but didn't work for a set that has non-sequential values. The data is also located in non-sequential cell locations. I don't know if this helps clarify the situation. But thank you so much for the CHOOSE suggestion. At least I got one set completed. "Aaargh" wrote: I'm trying to set up a formula that will check the value of a cell, then based on the value of that cell, will insert another value....i.e. If C2 =1, then G2 = A3 or if C2 = 2, then G2 = A4, or if C2 = 3, then G2 = A5. This will be across worksheets but all in the same workbook. The end product will be a table where the user will input just a few variables and Excel will populate the rest of the table. Can this be done? |
#9
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
need a formula
I'm glad the nested IF worked for you Aaargh, I think there are restrictions
on how many 'nests' you can have but if you've only got a few then I find it works well. IF's one of my faves! :) Best regards, Gareth |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|