MrExcel Publishing
Your One Stop for Excel Tips & Solutions


Posted by Keith on December 20, 2001 8:46 AM

I am trying to make a list to choose between 12 names, and if you choose a name the phone nuber will pop up in another cell, but the function if statement will only allow seven nested if statement. How can I fix this problem

Posted by Aladin Akyurek on December 20, 2001 8:57 AM

Keith --

Create a 2-column list in some worksheet consisting of names and corresponding phone numbers.

Select all the cells where you have the names and name it e.g., NAMES via the name Box on the Formula Bar (Don't include any label in the selection). Select now all of the cells of the 2-column list and name it, e.g., PHONES via the Name Box.

In a relevant cell in some sheet, say A1, construct a dropdown list. In order to do so,

activate A3;
activate Data|Validation;
Choose List for Allow;
Enter as Source


and click OK.

In C1 enter: =VLOOKUP(A3,PHONES,2,0)



Posted by Keith on December 20, 2001 11:27 AM

Posted by Keith on December 20, 2001 11:29 AM

Thank you Aladin you suggestion works really good.