I have an ocx that pops up a dialog when a specific method is called.
This dialog sometimes is hidden by the main application. I want to make the main form of the application the owner (or the parent) of the popup window in my ocx.
I can request from the user to give me the handle of the window (the main window of their application or the window that is currently hiding my popup).
I tried doing this by calling popup.CreateParented(handle) where handle is the HWND of the external application, but it doesn't work.
I even wonder if this is possible.
The other option I'm using which I hate is to set the form as StayOnTop. Aside from being (I believe) a bad programming practice, if another window pops up, the user gets stuck.