How do I the handle of a child window while only know its ID? I tried to type-cast with (HWND) but that didn't work...
How do I the handle of a child window while only know its ID? I tried to type-cast with (HWND) but that didn't work...
If you know its parent window/dialog
hWnd=GetDlgItem(hParent,ID);
may work if it is a control.
If it is a window or dialog you created I suggest storing the HWNDs in an array.
Also create some #defines for the indexes.
(I have a struct I store window data like HDC's, bitmaps ect in.)
"Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
Friedrich Nietzsche
"I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
George Best
"If you are going through hell....keep going."
Winston Churchill