OleObjects and someproperties

K

Kris

Hi.

I inserted object; combo box

Dim combo As OLEObject

Set combo = ActiveSheet.OLEObjects.Add(ClassType:="Forms.ComboBox.1",
Link:=False, DisplayAsIcon:=False, Left:=100, Top:=100.Top, Width:=96,
Height:=18)

I can set some of the properties

combo.LinkedCell = "$g$6"

but I also have to set ColumnCount and ColumnWidth properties of
combobox. I can do that manually, but they are not listed as a
properties in VBA

Ho to do that from VBA?

Thanks.
 
K

Kris

Thanks, but it works only if you have object on userform, not on worksheet.
Thanks anyway.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top