I had the exact same problem with that thread. Here is what I wanted to post.
VB Code:
Private Declare Function SetParent Lib "user32" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
Private Declare Function MoveWindow Lib "user32" (ByVal hwnd As Long, ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal bRepaint As Long) As Long
'Insert the following code to your first form (named Form1):
Private Sub Form_Load()
Load Form2
Form2.Show
Private Sub Form_Load()
'Replace the 'Form1' below with the name of the 'Parnt' Form
Dim r As Long
r = SetParent(Me.hWnd, Form1.hWnd)
End Sub
'To position the form once it has been made a part of the parent form, use this code:
'Replace '250, 250, 400, 400' with the form coordinates.
Call MoveWindow(Me.hwnd, 250, 250, 400, 400, 1)