SetUserObjectInformation function user32

Win32Result<bool> SetUserObjectInformation(
  1. HANDLE hObj,
  2. int nIndex,
  3. Pointer<NativeType> pvInfo,
  4. int nLength,
)

Sets information about the specified window station or desktop object.

To learn more, see learn.microsoft.com/windows/win32/api/winuser/nf-winuser-setuserobjectinformationw.

Implementation

Win32Result<bool> SetUserObjectInformation(
  HANDLE hObj,
  int nIndex,
  Pointer pvInfo,
  int nLength,
) {
  resolveGetLastError();
  final result_ = _SetUserObjectInformation(hObj, nIndex, pvInfo, nLength);
  return .new(value: result_ != FALSE, error: GetLastError());
}