SetClipboardData function Null safety user32

int SetClipboardData(
  1. int uFormat,
  2. int hMem
)

Places data on the clipboard in a specified clipboard format. The window must be the current clipboard owner, and the application must have called the OpenClipboard function.

HANDLE SetClipboardData(
  UINT   uFormat,
  HANDLE hMem
);

Implementation

int SetClipboardData(int uFormat, int hMem) {
  final _SetClipboardData = _user32.lookupFunction<
      IntPtr Function(Uint32 uFormat, IntPtr hMem),
      int Function(int uFormat, int hMem)>('SetClipboardData');
  return _SetClipboardData(uFormat, hMem);
}