November 5th, 2002 03:52 PM
How to set the style of the ComboBox control if it is dynamically added to the form
I dynamically add a ComboBox control to the form:
Set Combo1 = Controls.Add("VB.ComboBox", "Combo1")
I want to set its style to "Dropdown list":
Combo1.style = 2
But there is a compile error: "Can't assign to read-only property".
Then how to set the style of the ComboBox control if it is dynamically added to the form? Thanks a lot.
November 5th, 2002 04:57 PM
Check this site. Uses API.
It uses check box and option box but maybe can use combo
Last edited by WayneS; November 5th, 2002 at 05:00 PM.
Click Here to Expand Forum to Full Width