GetPointerType function (winuser.h)

Retrieves the pointer type for a specified pointer.


BOOL GetPointerType(
  [in]  UINT32             pointerId,
  [out] POINTER_INPUT_TYPE *pointerType


[in] pointerId

An identifier of the pointer for which to retrieve pointer type.

[out] pointerType

An address of a POINTER_INPUT_TYPE type to receive a pointer input type.

Return value

If the function succeeds, the return value is non-zero.

If the function fails, the return value is zero. To get extended error information, call GetLastError.


An application can use the GetPointerType function to determine the pointer type if it wishes to react differently to pointers of different types.

Note  This function will never return with the generic PT_POINTER type.


Minimum supported client Windows 8 [desktop apps only]
Minimum supported server Windows Server 2012 [desktop apps only]
Target Platform Windows
Header winuser.h (include Windows.h)
Library User32.lib
DLL User32.dll
API set ext-ms-win-rtcore-ntuser-wmpointer-l1-1-0 (introduced in Windows 10, version 10.0.14393)

See also