Retrieves a handle to the current window station for the calling process.
#Include <WinAPIEx.au3>
_WinAPI_GetProcessWindowStation ( )
| None. | 
| Success | Handle to the window station for the current process. | 
| 失败: | 返回 0 并设置 @error 标志为非 0 值. | 
在MSDN中搜索
#Include <APIConstants.au3>
#Include <WinAPIEx.au3>
Opt('MustDeclareVars', 1)
Global $hObj[2] = [_WinAPI_GetProcessWindowStation(), _WinAPI_GetThreadDesktop(_WinAPI_GetCurrentThreadID())]
For $i = 0 To 1
    If Not $i Then
        ConsoleWrite('-------------------------------' & @CR)
    EndIf
    ConsoleWrite('Handle: ' & $hObj[$i] & @CR)
    ConsoleWrite('Type:   ' & _WinAPI_GetUserObjectInformation($hObj[$i], $UOI_TYPE) & @CR)
    ConsoleWrite('Name:   ' & _WinAPI_GetUserObjectInformation($hObj[$i], $UOI_NAME) & @CR)
    ConsoleWrite('-------------------------------' & @CR)
Next