|
-
Aug 18th, 2001, 06:05 PM
#1
Thread Starter
Member
usercontrol problems
I have a usercontrol that has picture boxes on it. The usercontrol has the property ControlContainer set to true. I want to be able to (just like on a form) drop a control on a picturebox in the usercontrol, and have that picturebox contain the control. not the usercontrol. This is so I can hide the picturebox and any controls contained within it all get hidden to.
Ive seen this capability in many other active X controls (able to drop controls onto the activex, and have the control be contained by a container within the control instead of the usercontrol itself.
Im thinking that this might mean me having to implement the ISimpleFrame interface myself. Just dont know what to do.
Gregg
-
Aug 19th, 2001, 12:40 PM
#2
Frenzied Member
I've only written two UserControls so I may not be the best person to answer this question. My first thought was the SetParent API
Declare Function SetParent Lib "user32" Alias "SetParent" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
Call SetParent(Child.hWnd, Parent.hWnd)
Greg
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
|