可以手动写代码添加的...建议写进一个类里..封装...以后升级方便呀 如.......将写下代码拷在窗体中...什么也不用写..呵呵 试试...就是自动生成一些控件,,而且可以带事件 Option Explicit Private WithEvents Command1 As CommandButton Dim text1 As TextBoxPrivate Sub Command1_Click() MsgBox text1 End SubPrivate Sub Form_Load() Set Command1 = Controls.Add("VB.CommandButton", "command1") With Command1 .Visible = True .Width = 1500 .Caption = "msgbox" .Top = 1000 .Left = 1000 End With Set text1 = Controls.Add("VB.TextBox", "text1") With text1 .Visible = True .Width = 2000 .Text = "你好" .Top = 1000 .Left = 3000 End With End Sub慢慢学吧..兄弟 欢迎来我的QQ群:1464730
如.......将写下代码拷在窗体中...什么也不用写..呵呵
试试...就是自动生成一些控件,,而且可以带事件
Option Explicit
Private WithEvents Command1 As CommandButton
Dim text1 As TextBoxPrivate Sub Command1_Click()
MsgBox text1
End SubPrivate Sub Form_Load()
Set Command1 = Controls.Add("VB.CommandButton", "command1")
With Command1
.Visible = True
.Width = 1500
.Caption = "msgbox"
.Top = 1000
.Left = 1000
End With
Set text1 = Controls.Add("VB.TextBox", "text1")
With text1
.Visible = True
.Width = 2000
.Text = "你好"
.Top = 1000
.Left = 3000
End With
End Sub慢慢学吧..兄弟
欢迎来我的QQ群:1464730
为此,我采用shell调用外部程序的方法,但却无法完全地实现MDI对子窗体的管理功能,可否有其他的办法?