动态生成的对象怎么调用事件?(VB6)
动态生成的对象怎么调用事件?(VB6)
[解决办法]
Dim MyControl As Control
Set MyControl = Me.Controls.Add( "vb.commandbutton ", "mybuttontest ")
With MyControl
.Visible = True
.Left = 100
.Top = 150
.Caption = "test1 "
End With
调用事件就是private sub MyControl_click()
end sub
[解决办法]
在VB中动态添加可响应消息的控件
http://www.applevb.com/art/dyn_control.txt