ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Hiding a Combo Box. (https://www.excelbanter.com/excel-programming/281190-hiding-combo-box.html)

cwsax

Hiding a Combo Box.
 
Hi all,

I attempting to hide a combo box control that is created
directly from the "Control Toolbox." This particular
ComboBox is embedded within Sheet1, not a userform. The
value of checkbox must be unchecked or false in order for
combo box to be hidden. (Excel 2000)

The property I have been trying to attempt this with the
ComboBox .Visible property. So far this hasn't been
successful. Here is a sample of what I have done.

Sub Checkbox_data_source_information_type_of_email()

With Worksheets("Sheet1")
.OLEObjects("cboComboBox1").Object _
.Visible = False
.OLEObjects("cboComboBox2").Object
.Visible = False
End With

The error I get is the Property doesn't support this
method (Run time #438.) Any help you could give would be
greatly appreciated.

Mike Tomasura

Hiding a Combo Box.
 
Tey this

ComboBox1.Visible = False


"cwsax" wrote in message
...
Hi all,

I attempting to hide a combo box control that is created
directly from the "Control Toolbox." This particular
ComboBox is embedded within Sheet1, not a userform. The
value of checkbox must be unchecked or false in order for
combo box to be hidden. (Excel 2000)

The property I have been trying to attempt this with the
ComboBox .Visible property. So far this hasn't been
successful. Here is a sample of what I have done.

Sub Checkbox_data_source_information_type_of_email()

With Worksheets("Sheet1")
.OLEObjects("cboComboBox1").Object _
.Visible = False
.OLEObjects("cboComboBox2").Object
.Visible = False
End With

The error I get is the Property doesn't support this
method (Run time #438.) Any help you could give would be
greatly appreciated.




cwsax

Hiding a Combo Box.
 
I think I have tried this but to no avail. I think my
main issue is refering back to the combobox within the
sheet in VBA. In other words how do you refer to a named
combo box e.g. (cboLotusNotesFoldersDocuments). Everytime
I refer to this name I am told the variable is not defined
and when I setup a Dim cboLotusNotesFoldersDocuments as
CombBox I still can't set the Visible property to False.

Thanks I am very frustrated with the Excel Object Model
right now since I am a novice. Thanks.

-----Original Message-----
Tey this

ComboBox1.Visible = False


"cwsax" wrote in

message
...
Hi all,

I attempting to hide a combo box control that is created
directly from the "Control Toolbox." This particular
ComboBox is embedded within Sheet1, not a userform. The
value of checkbox must be unchecked or false in order

for
combo box to be hidden. (Excel 2000)

The property I have been trying to attempt this with the
ComboBox .Visible property. So far this hasn't been
successful. Here is a sample of what I have done.

Sub Checkbox_data_source_information_type_of_email()

With Worksheets("Sheet1")
.OLEObjects("cboComboBox1").Object _
.Visible = False
.OLEObjects("cboComboBox2").Object
.Visible = False
End With

The error I get is the Property doesn't support this
method (Run time #438.) Any help you could give would

be
greatly appreciated.



.


Mike Tomasura

Hiding a Combo Box.
 
If you are still in design mode you will see the object.
Try to exit design mode.



"cwsax" wrote in message
...
I think I have tried this but to no avail. I think my
main issue is refering back to the combobox within the
sheet in VBA. In other words how do you refer to a named
combo box e.g. (cboLotusNotesFoldersDocuments). Everytime
I refer to this name I am told the variable is not defined
and when I setup a Dim cboLotusNotesFoldersDocuments as
CombBox I still can't set the Visible property to False.

Thanks I am very frustrated with the Excel Object Model
right now since I am a novice. Thanks.

-----Original Message-----
Tey this

ComboBox1.Visible = False


"cwsax" wrote in

message
...
Hi all,

I attempting to hide a combo box control that is created
directly from the "Control Toolbox." This particular
ComboBox is embedded within Sheet1, not a userform. The
value of checkbox must be unchecked or false in order

for
combo box to be hidden. (Excel 2000)

The property I have been trying to attempt this with the
ComboBox .Visible property. So far this hasn't been
successful. Here is a sample of what I have done.

Sub Checkbox_data_source_information_type_of_email()

With Worksheets("Sheet1")
.OLEObjects("cboComboBox1").Object _
.Visible = False
.OLEObjects("cboComboBox2").Object
.Visible = False
End With

The error I get is the Property doesn't support this
method (Run time #438.) Any help you could give would

be
greatly appreciated.



.





All times are GMT +1. The time now is 06:05 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com