Click to See Complete Forum and Search --> : ComboBoxEx: How to set read-only status?


April 29th, 1999, 03:28 AM
How do you code the ComboBoxEx Control as read-only?

I tried the following code, but it doesn't work:
CEdit* pCombo = (CEdit*)GetDlgItem(IDC_XXX); // XXX is the name of your ComboBoxEx Ctrl
pCombo->SetReadOnly();

April 29th, 1999, 04:38 AM
You dont want the user to change the strings in the ComboBox. If so, then change the style of the ComboBox to "DropList". You can change it in the properties of the ComboBox in the dialog editor