|
-
May 18th, 2000, 01:06 AM
#1
Thread Starter
Hyperactive Member
Hi, I'm using SetParent to capture an app's window (App A) into another app's window (App B). I later want to release App A so another application can capture it, but when I use SetParent again from another app, App A won't leave. I even tried to force the desktop window to become its new parent (by using vbNull as the parent argument in SetParent) and that doesn't work either. What can I do??
Thanks.
[Edited by WadeD on 05-18-2000 at 02:10 PM]
-
May 18th, 2000, 01:38 AM
#2
This should work just fine:
Code:
Private Sub Command1_Click()
Dim lHwnd As Long
Dim lDesktop As Long
Dim lSomeOtherApp As Long
lDesktop = GetDesktopWindow
'Here I'm assuming that you already have a
'window handle of that form and a window handle
'of the application you want to assign your form to
Call SetParent(lHwnd, lSomeOtherApp)
'Do your stuff here
'Now set your form to be a child to a desktop again
Call SetParent(lHwnd, lDesktop)
End Sub
-
May 18th, 2000, 01:42 AM
#3
transcendental analytic
And here's the fast way
Code:
Setparent yourwnd&, 0
Use  
writing software in C++ is like driving rivets into steel beam with a toothpick.
writing haskell makes your life easier:
reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.
-
May 18th, 2000, 02:33 AM
#4
Thread Starter
Hyperactive Member
Thanks guys.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|