WM_SETCURSOR question

This is a discussion on WM_SETCURSOR question within the Windows Programming forums, part of the Platform Specific Boards category; Normally, I would use wParam of WM_SETCURSOR message to identify the child window the cursor is over. Something like this... ...

  1. #1
    Registered User
    Join Date
    Sep 2001
    Posts
    39

    WM_SETCURSOR question

    Normally, I would use wParam of WM_SETCURSOR message to identify the child window the cursor is over.
    Something like this...

    hwndChildWindow = CreateWindow(.....WS_CHILD...

    case WM_SETCURSOR:
    if((HWND) wParam == hwndChildWindow)
    {
    // Do whatever
    }

    But this time I have to use child-window identifiers, instead of handles, to differentiate one child window from another. How can I get the above code to work using child-window identifiers instead of handles??

    Thanks

  2. #2
    erstwhile
    Join Date
    Jan 2002
    Posts
    2,227
    int nCtrlID=GetDlgCtrlID(hwnd);

    hope that helps.

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21