thanosm2003
Newcomer
- Joined
- Feb 28, 2008
- Messages
- 1
The following code creates a new command button, at run time, named btnTest1. How can i add events(like btnTest1_click) to this object? How can i add code that hadles the events for this object?
Dim myButton As Button = New Button()
Me.Controls.Add(myButton)
myButton.Name = "btnTest1"
myButton.Size = New Size(45, 45)
myButton.Location = New Point(10, 10)
Dim myButton As Button = New Button()
Me.Controls.Add(myButton)
myButton.Name = "btnTest1"
myButton.Size = New Size(45, 45)
myButton.Location = New Point(10, 10)