Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
"For" help (I think?)
Good morning all-
I have a quick question for you concerning a selecting an item out of a listbox, allowing another userform pop up. In listbox1, I have 51 line items, with a SelectButton and a CancelButton. What would be a good code for the following: If listindex 1 is selected, then show userform1... If listindex 2 is selected, then show userform2... If listindex 51 is selected, then show userform51 I'm thinking something along the lines of: Private Sub SelectButton_Click() Dim I as Integer For I = 1 to 51 if listbox1.selected(I) then userform(I).open end if next I End Sub How far am I off the beaten track here? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell | Excel Discussion (Misc queries) | |||
change "true" and "false" to "availble" and "out of stock" | Excel Worksheet Functions | |||
HELP on "left","right","find","len","substitute" functions | Excel Discussion (Misc queries) | |||
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next | New Users to Excel | |||
If changed array formula reduce ""\""\""\ - signs to #Missing, will it make ... | Excel Programming |