View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 6,953
Default Select case or If then

Select Case does not require a numeric value. It is native to VBA which is
the same in Excel and Word.

You can have a dropdown without using a macro. See Data=Validation using
the List Option.

Greater information is at Debra Dalgleish's site:

Debra Dalgleish
http://www.contextures.com/tiptech.html

Having a database of values on another sheet, possibly hidden will provide
the ability to lookup the address of the selected value and display it below
the dropdown

=if(A1<"",Vlookup(A1,sheet2!A:F,2,False),"")

as an example.

--
Regards,
Tom Ogilvy


"Lenny" wrote:

I develop electronic form templates in Word, however, I currently have the
opportunity to develop a shipping document in Excel. I want to insert a
dropdown in cell A1 that contains a single list of the companys plants. Once
the plant has been selected from the dropdown, the appropriate address will
proliferate cell A2. I do this using SelectCase in Word but I notice that
the construction of the code is different in Excel. I see that in Excel the
items that populate the code need to be entered into a cell range on the
spreadsheet, workbook, or external document. I also note that the Select
case in Excel seems to ask for a 'numeric' value and the anticipated returned
numeric value.....is there a counterpart I can use in Excel to get my desired
results? Best regards - Lenny