Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I need to pass a value from a list box to a worksheet and
get a number of values back to display to a user. I'm using a listbox for the user to choose the original value. Does anyone have VB code to help me get started? |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Private Sub Combobox1_Click()
with combobox1.listIndex case 0 returnNumbers = Array(1,2,3) case 1 returnNumbers = array(4,5,6) case else returnNumbers = array(7,8,9) End Case End Sub In a general module Public returnNumbers as Variant Public Sub MyFunc() Application.Volatile MyFunc = returnNumbers End Function Select A1 to C1 in the formulabar enter =MyFunc() end with Ctrl+Shift+Enter -- Regards, Tom Ogilvy "George" wrote in message ... I need to pass a value from a list box to a worksheet and get a number of values back to display to a user. I'm using a listbox for the user to choose the original value. Does anyone have VB code to help me get started? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
formula for % passing | Excel Worksheet Functions | |||
Passing Variables | Excel Discussion (Misc queries) | |||
Passing Variables | Excel Programming | |||
passing strings | Excel Programming | |||
PASSING A STRING VALUE | Excel Programming |