CreateWindowStation function user32
Win32Result<HWINSTA>
CreateWindowStation(
- PCWSTR? lpwinsta,
- int dwFlags,
- int dwDesiredAccess,
- Pointer<
SECURITY_ATTRIBUTES> ? lpsa,
Creates a window station object, associates it with the calling process, and assigns it to the current session.
To learn more, see learn.microsoft.com/windows/win32/api/winuser/nf-winuser-createwindowstationw.
Implementation
Win32Result<HWINSTA> CreateWindowStation(
PCWSTR? lpwinsta,
int dwFlags,
int dwDesiredAccess,
Pointer<SECURITY_ATTRIBUTES>? lpsa,
) {
final result_ = CreateWindowStationW_Wrapper(
lpwinsta ?? nullptr,
dwFlags,
dwDesiredAccess,
lpsa ?? nullptr,
);
return Win32Result(value: HWINSTA(result_.value.ptr), error: result_.error);
}