7,759
社区成员
发帖
与我相关
我的任务
分享
Option Explicit
Private Declare Function SetParent Lib "user32.dll" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
Private Sub Command1_Click()
Form2.Show
'' 使用API设置Form2的父窗口为Form1
SetParent Form2.hWnd, Form1.hWnd
Form3.Show
'' 使用API设置Form3的父窗口为Form2
SetParent Form3.hWnd, Form2.hWnd
End Sub