Combo box control.
1. When you click the downward triangle of the control in the editing status, a height-adjustable figure is displayed. Raise the height. Otherwise, the drop-down list cannot be displayed during execution.
2. Add options for the combo box. In the editing status, select the properties of the combo box control, select the data tag, add options in the editing box, and press Ctrl-enter to add the next option.
3. Add a variable to the combo box
Combo box has two variables: ccombobox class variable and cstring variable.
The ccombobox variable is used to set the attributes of the combo box. It is generally used in the oninitdialog () function of the cdialog class. Add a variable in classwizard and select control in the category when adding the variable. For example, ccombobox. setcursel (0) is used to set the initial value of the drop-down menu. For details, refer to msdn.
The cstring variable is used to store the option values selected from the drop-down menu. Similarly, when the option changes, use the updatedata (true) function to update the value of the variable.