--------------------------------------------------------------------------------
The LoadCursor function loads the specified cursor resource from the executable (.EXE) file associated with an application instance.
Note This function has been superseded by the LoadImage function.
Syntax
HCURSOR LoadCursor( HINSTANCE hInstance,
LPCTSTR lpCursorName
);
Parameters
hInstance
[in] Handle to an instance of the module whose executable file contains the cursor to be loaded.
lpCursorName
[in] Pointer to a null-terminated string that contains the name of the cursor resource to be loaded. Alternatively, this parameter can consist of the resource identifier in the low-order word and zero in the high-order word. The MAKEINTRESOURCE macro can also be used to create this value. To use one of the predefined cursors, the application must set the hInstance parameter to NULL and the lpCursorName parameter to one the following values:
IDC_APPSTARTING
Standard arrow and small hourglass
IDC_ARROW
Standard arrow
IDC_CROSS
Crosshair
IDC_HAND
Windows 98/Me, Windows 2000/XP: Hand
IDC_HELP
Arrow and question mark
IDC_IBEAM
I-beam
IDC_ICON
Obsolete for applications marked version 4.0 or later.
IDC_NO
Slashed circle
IDC_SIZE
Obsolete for applications marked version 4.0 or later. Use IDC_SIZEALL.
IDC_SIZEALL
Four-pointed arrow pointing north, south, east, and west
IDC_SIZENESW
Double-pointed arrow pointing northeast and southwest
IDC_SIZENS
Double-pointed arrow pointing north and south
IDC_SIZENWSE
Double-pointed arrow pointing northwest and southeast
IDC_SIZEWE
Double-pointed arrow pointing west and east
IDC_UPARROW
Vertical arrow
IDC_WAIT
Hourglass
Return Value
If the function succeeds, the return value is the handle to the newly loaded cursor.
If the function fails, the return value is NULL. To get extended error information, call GetLastError.
The LoadCursor function loads the specified cursor resource from the executable (.EXE) file associated with an application instance.
Note This function has been superseded by the LoadImage function.
Syntax
HCURSOR LoadCursor( HINSTANCE hInstance,
LPCTSTR lpCursorName
);
Parameters
hInstance
[in] Handle to an instance of the module whose executable file contains the cursor to be loaded.
lpCursorName
[in] Pointer to a null-terminated string that contains the name of the cursor resource to be loaded. Alternatively, this parameter can consist of the resource identifier in the low-order word and zero in the high-order word. The MAKEINTRESOURCE macro can also be used to create this value. To use one of the predefined cursors, the application must set the hInstance parameter to NULL and the lpCursorName parameter to one the following values:
IDC_APPSTARTING
Standard arrow and small hourglass
IDC_ARROW
Standard arrow
IDC_CROSS
Crosshair
IDC_HAND
Windows 98/Me, Windows 2000/XP: Hand
IDC_HELP
Arrow and question mark
IDC_IBEAM
I-beam
IDC_ICON
Obsolete for applications marked version 4.0 or later.
IDC_NO
Slashed circle
IDC_SIZE
Obsolete for applications marked version 4.0 or later. Use IDC_SIZEALL.
IDC_SIZEALL
Four-pointed arrow pointing north, south, east, and west
IDC_SIZENESW
Double-pointed arrow pointing northeast and southwest
IDC_SIZENS
Double-pointed arrow pointing north and south
IDC_SIZENWSE
Double-pointed arrow pointing northwest and southeast
IDC_SIZEWE
Double-pointed arrow pointing west and east
IDC_UPARROW
Vertical arrow
IDC_WAIT
Hourglass
Return Value
If the function succeeds, the return value is the handle to the newly loaded cursor.
If the function fails, the return value is NULL. To get extended error information, call GetLastError.