CreateWindow function requires an application handle in it's hWndParent paramter. How can i opbtain this handle using some API call?
Printable View
CreateWindow function requires an application handle in it's hWndParent paramter. How can i opbtain this handle using some API call?
What kind of application?
Take a look at AfxGetInstanceHandle().
It's not an MFC app, it's a borland app.
The hWndParent parameter should be the handle to the Parent window of the window. If the window has no parent you can enter HWND_DESKTOP.
thanks, but I will still like to know if their is a way to get a handle to you application for whatever purpose.
Do you mean the HINSTANCE of your program?
It is a parameter of you winmain function. Just save it to a global variable or somewhere else.