This example lets you find the current Desktop object and retrieves the current lockup automatic dim option setting.
WPDesktop *Desktop; BOOL bAutoDim; Desktop = _wpclsQueryObjectFromPath("<WP_DESKTOP>"); bAutoDim = _wpQueryLockupAutoDim(Desktop);