Hi guys searched and could not find anything, so Iam adding these two how to's
You can do it with interop:
Declare Auto Function SetParent Lib "user32" (ByVal hWndChild As IntPtr,
ByVal nWndPArent As IntPtr) As Integer
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim frm As New Form2
SetParent(frm.Handle, Me.SplitContainer1.Panel2.Handle)
frm.Show()
End Sub
You can do it without interop too:
Dim frm As New Form2
frm.TopLevel = False
frm.Parent = Me.SplitContainer1.Panel2
frm.Show
Enjoy
I Code there for I Am!
Comments
Join the conversation! Your thoughts help the community grow.