Enumerates all desktops associated with the specified window station of the calling process
_WinAPI_EnumDesktops ( $hStation )
|$hStation||Handle to the window station whose desktops are to be enumerated. This handle must have the
$WINSTA_ENUMDESKTOPS access right.
|Success:||The array of the desktop names. The zeroth array element contains the number of desktop.|
|Failure:||Sets the @error flag to non-zero.|
The _WinAPI_EnumDesktops() enumerates only those desktops for which the calling process has the
$DESKTOP_ENUMERATE access right.
Search EnumDesktops in MSDN Library.