Question Attach a form to the window of a separate process?

J. Scott Elblein

Well-known member
Joined
Dec 14, 2006
Messages
166
Location
Chicago
Programming Experience
10+
What is the usual method to attach a vb form to the window of another process? For example, the program "Listary" attaches a "toolbar" (probably just a small form) to OpenFileDialogs, and moves along with it if the OFD is moved:



I'm hoping to save a lot of time and find a pre-made example since it seems like this would hardly be the first time it's ever been done.

Is it some combo of setting a timer to constantly check the position of the other window via winAPI, read it's coords, and set my own form's coords? Or perhaps a SetParent API call, or something?
 
Ty @JohnH , tested it out and works great. Rather than do all the conversion to VB for it though, think I'm just gonna use this as an opportunity to finally learn WPF + C#, lol.
 
Back
Top