Home |
Search |
Today's Posts |
|
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Multiple If's, one variable. And filename as cell contents
You could try a "lookup" table with the array lookup function. Have a look
at Help. Basically, this would allow you to centralize your input possibilities and the response they each generate. For example... Q: How many miles did you run? A: 13 =LOOKUP("13",{"2","5","13","200";"short distance", "average jog", "half marathon", "ultra marathon"}) Msg: "This is considered a half marathon." -- ______________________ "peace - it's worth killing for" - Bush "Darrin Henry" wrote in message ... : Hello, : I have a few questions that are currently stumping me. : : 1) I have an input box. What the user puts in is declared as a variable. : Based on what they put in I want to return a msgbox. The problem is : there are 50 possible valid entries the user can input. Will multiple IF : statements work? Or another way? : : 2) I also I am trying to create a command button, that will save the : workbook, however, the filename is going to be the contents of a cell. : This is what I have now: : : Private Sub CommandButton1_Click() : : ActiveWorkbook.SaveAs Filename:="C:\" : Worksheets("sheet1").Range("f9:g9").Value ".xls" : End Sub : : Any idea what is wrong? I get a runtime error 1004, on it. Thanks. : : *** Sent via Developersdex http://www.developersdex.com *** : Don't just participate in USENET...get rewarded for it! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Create filename based on cell contents | Excel Worksheet Functions | |||
Vlookup Cell Contents Filename | Excel Worksheet Functions | |||
Cell Contents to identify source Filename | Excel Discussion (Misc queries) | |||
Entering a filename as a variable into cell similar as for footer | Excel Discussion (Misc queries) | |||
Multiple If's, one variable. And filename as cell contents | Excel Programming |