My aim is to get the handle of a window I click. I'm using a global mouse hook and then GetCursorPos
and WindowFromPoint
). When I click on a button (or other controls) I get the button's handle. Using GetParent
I can find the parent window, so I need to check if the handle I have is a window or not.
I have tried GetClassName
but it's not what I'm looking for.
Any ideas appreciated (also using other approaches).