Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Referencing a ComboBox control from a Workbook Object?
Hi Everybody,
I have a ComboBox control on a Worksheet. From the code behind of the Worksheet I am able reference it and alter it's properties i.e. MyComboBox.Text = "Hello" My goal is to reference that same control from the code behind of the Workbook instead? i.e. ThisWorkbook.Worksheets("Sheet1"). ? Thanks for any help! Sam P.S. ThisWorkbook.Worksheets("Sheet1").MyComboBox.Text doesn't work? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Referencing a ComboBox control from a Workbook Object?
See the message thread 5 root posts above this one with subject: editing control/form objects on a worksheet
by: Ricky M. Medley.... Is searching for very similair answer. Can watch there also for any responses. regards ricky "debartsa" wrote in message ... Hi Everybody, I have a ComboBox control on a Worksheet. From the code behind of the Worksheet I am able reference it and alter it's properties i.e. MyComboBox.Text = "Hello" My goal is to reference that same control from the code behind of the Workbook instead? i.e. ThisWorkbook.Worksheets("Sheet1"). ? Thanks for any help! Sam P.S. ThisWorkbook.Worksheets("Sheet1").MyComboBox.Text doesn't work? |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Referencing a ComboBox control from a Workbook Object?
Private Sub Workbook_SheetActivate(ByVal Sh As Object)
If Sh.Name = "Sheet2" Then ThisWorkbook.Worksheets("Sheet1").MyCombobox.Text _ = Format(Time, "hh:mm:ss.00") End If End Sub worked fine for me as an example of using that notation in th eThisworkbook event. -- Regards, Tom Ogilvy "Ricky M. Medley" wrote in message ... See the message thread 5 root posts above this one with subject: editing control/form objects on a worksheet by: Ricky M. Medley.... Is searching for very similair answer. Can watch there also for any responses. regards ricky "debartsa" wrote in message ... Hi Everybody, I have a ComboBox control on a Worksheet. From the code behind of the Worksheet I am able reference it and alter it's properties i.e. MyComboBox.Text = "Hello" My goal is to reference that same control from the code behind of the Workbook instead? i.e. ThisWorkbook.Worksheets("Sheet1"). ? Thanks for any help! Sam P.S. ThisWorkbook.Worksheets("Sheet1").MyComboBox.Text doesn't work? |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Referencing a ComboBox control from a Workbook Object?
to all that review....
one of my errors was to use activeworkbook.worksheets....etc. which yields a compile error thanks tom "Tom Ogilvy" wrote in message ... Private Sub Workbook_SheetActivate(ByVal Sh As Object) If Sh.Name = "Sheet2" Then ThisWorkbook.Worksheets("Sheet1").MyCombobox.Text _ = Format(Time, "hh:mm:ss.00") End If End Sub worked fine for me as an example of using that notation in th eThisworkbook event. -- Regards, Tom Ogilvy "Ricky M. Medley" wrote in message ... See the message thread 5 root posts above this one with subject: editing control/form objects on a worksheet by: Ricky M. Medley.... Is searching for very similair answer. Can watch there also for any responses. regards ricky "debartsa" wrote in message ... Hi Everybody, I have a ComboBox control on a Worksheet. From the code behind of the Worksheet I am able reference it and alter it's properties i.e. MyComboBox.Text = "Hello" My goal is to reference that same control from the code behind of the Workbook instead? i.e. ThisWorkbook.Worksheets("Sheet1"). ? Thanks for any help! Sam P.S. ThisWorkbook.Worksheets("Sheet1").MyComboBox.Text doesn't work? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
form control combobox | Excel Discussion (Misc queries) | |||
2 Label Options - Forms Object vs Control Box Object | Excel Discussion (Misc queries) | |||
Control ToolBox ComboBox | Excel Discussion (Misc queries) | |||
HELP PLEASE..Inserting combobox (ActiveX control) makes workbook c | Excel Discussion (Misc queries) | |||
How to pass valve in combobox object to cell | Excel Programming |