Group: System Information - Library: user32
Retrieves various system metrics (widths and heights of display elements) and system configuration settings.
Creating irregularly shaped FoxPro form using transparency color key
Retrieving various system metrics
Clipping mouse cursor area
An alternative way of setting Form.Closable to False
Round FoxPro form
Tracking mouse movement to detect when to start dragging
Splash Screen for the VFP application
How to draw custom Window Caption on FoxPro form
Placing On-screen Alert on top of all windows
GDI+: how to make VFP controls visually shake and shudder
How to make a VFP form fading out when released (GDI+ version)
How to make a VFP form fading out when released (GDI version)
int GetSystemMetrics(
int nIndex // system metric or configuration setting
);
DECLARE INTEGER GetSystemMetrics IN user32 INTEGER nIndex
nIndex [in] Specifies the system metric or configuration setting to retrieve.
If the function succeeds, the return value is the requested system metric or configuration setting.
All dimensions retrieved by GetSystemMetrics are in pixels.
The SM_REMOTESESSION system metric is used in a Terminal Services environment. If the calling process is associated with a Terminal Services client session, the return value is nonzero.
The SM_REMOTECONTROL is used in a Terminal Services environment. Its value is nonzero if the current session is remotely controlled; otherwise, 0.
Read post Detecting Workstation state changes in Calvin Hsia`s weblog.
System Metrics Foundation Class included in VFP8 and 9 installations provides access to system metric information as mousewheel present, number of mouse buttons, and number of monitors are provided with the class, but any valid system metric can be queried.
See also: SystemParametersInfo, SYSMETRIC( )
Allegedly, both GetSystemMetrics(SM_CXSIZE) and GetTitleBarInfo return wrong values for Vista Aero. For the latter, sending the WM_GETTITLEBARINFOEX suggested to be a replacement.
Vista Aero Issues on FoxPro Wiki.