Style Property

Specifies the style of a control. Available at design time and run time.

 [Form.]Control.Style[= nType]

Property Values

  • nType
    For ComboBox controls, the settings for the Style property are as follows:
    Setting Description
    0    Drop-down Combo. Includes a drop-down list and an edit area. The user can select from the list or enter characters in the edit area.
    2    Drop-down List. The user must select from the drop-down list.

Follow these guidelines in deciding which setting to choose:

  • Set Style to 0 (Dropdown Combo) to give the user a list of choices and also enable the user to enter a selection in the edit area. Style 0 saves space on the Form because the list portion closes when the user makes a selection.
  • Set Style to 2 (Dropdown List) to display a fixed list of choices from which the user can select one. The list portion closes when the user selects an item.

For CheckBox and OptionButton controls, the settings for the Style property are as follows:

Setting Description
0    Standard.
1    Graphical. The button appears like a command button. It can contain both graphics and text. When the button contains both, the text is always centered at the bottom of the button.

For CommandButton controls, the settings for the Style property are as follows:

Setting Description
0    Standard
1    Invisible

For TextBox controls, the settings for the Style property are:

Setting Description
0    (Default) Normal.
1    Included for backward compatibility with the FoxPro version 2.x @ ... SAY command. The TextBox is read-only and cannot receive the focus.

For Toolbar separator objects, the settings for the Style property are as follows:

Setting Description
0    (Default) Normal. No vertical line rule.
1    Specifies a vertical line as the separator object in Toolbars (Visible at runtime only).

See Also

Click Event | DblClick Event

Applies To: CheckBox | ComboBox | CommandButton | OptionButton | Separator | TextBox