Condividi tramite


ItemBackColor, ItemForeColor Properties

Specifies the background or foreground color used to display the text of items in a ComboBox or ListBox control. Available at design time and run time.

Control.ItemBackColor [= nColor ]
-or-
Control.ItemBackColor = RGB( nRedValue, nGreenValue, nBlueValue )

Control.ItemForeColor [ = nColor ]
-or-
Control.ItemForColor = RGB( nRedValue, nGreenValue, nBlueValue )

Property Values

  • nColor
    Specifies an integer that represents the color of the text. For more information, see the color table in the BackColor_ForeColor Properties topic.

Remarks

To choose or define colors, double-click any of the color properties in the Properties window to display the Color dialog box. The red, green, and blue color values corresponding to the color you choose become the settings for these properties after you close the Color dialog box.

See Also

BackColor, ForeColor Properties

Applies To: ComboBox Control | ListBoxControl