IDesktopWallpaper::GetMonitorDevicePathAt method
Retrieves the unique ID of one of the system's monitors.
Syntax
HRESULT GetMonitorDevicePathAt(
[in] UINT monitorIndex,
[out] LPWSTR *monitorID
);
Parameters
- monitorIndex [in]
-
The number of the monitor. Call GetMonitorDevicePathCount to determine the total number of monitors.
- monitorID [out]
-
A pointer to the address of a buffer that, when this method returns successfully, receives the monitor's ID.
Return value
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code, including the following.
| Return code | Description |
|---|---|
|
A NULL pointer was provided in monitorID. |
Remarks
This method can be called on monitors that are currently detached but that have an image assigned to them. Call GetMonitorRECT to distinguish between attached and detached monitors.
Requirements
|
Minimum supported client |
Windows 8 [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows Server 2012 [desktop apps only] |
|
Header |
|
|
IDL |
|
See also
Show: