SetBackColor method


Available for all objects except Image, HScroll, VScroll, ToolBar, StatusBar ProgressBar, Slider, TabStrip, UpDown, Animate, IpAddress, ImageCombo, Calendar, DateTime and HotKey.

Syntax

Invoke SetBackColor, hWnd, crBackColor

Function

Sets the BackColor property for an object.

Parameters

hWnd

Handle to the object.

crBackColor

A DD value specifying the new back color for the object.

Return value

Eax returns TRUE if succesful, or FALSE if not.


REMARKS
: The most significant byte of crBackColor specifies whether the color is an RGB value (00H) or a system color (80H), while the other three bytes are the corresponding RGB values. For example, a value 00FF0000H means blue, 0000FF00H means green and 000000FFH means red, while 80000005H means the system color number 5 (COLOR_WINDOW).