Here is a library code source build with sharpdevelop, you can add textChanged events to all you textbox controls :
For #Develop :
Imports System.Windows.Forms
Imports System.Drawing
Public Class txtBox
Implements IDisposable 'Inherit from IDisposable if you need Basic4ppc to free resources when the application is closed.
Private WithEvents myControl As System.Windows.Forms.TextBox'The "real" object.
Public Event TextChanged As EventHandler 'The event handler name must match the event name.
Private eventObject() As Object 'One object[] for each event (one event here).
Sub New( ByVal frm as Form, ByVal txtBox As Control)
Dim ctrl As Windows.Forms.Control
For Each ctrl In frm.Controls
If (ctrl.Name = txtBox.Name) Then
eventObject = New Object() {Me, "TextChanged"}
AddHandler txtBox.TextChanged, AddressOf myControl_TextChanged
Exit Sub
End If
Next
msgbox ("Not Found")
End Sub
Private Sub myControl_TextChanged(ByVal sender As Object, ByVal e As EventArgs) Handles myControl.TextChanged
RaiseEvent TextChanged(eventObject, Nothing)
End Sub
Public Sub Dispose() Implements System.IDisposable.Dispose
If Not myControl Is Nothing Then
myControl.Dispose()
End If
End Sub
End Class
For Basic4PPC :
Sub App_Start
Form1.Show
sb.New1(Form1.Name,txt.Name)
sb.New1(Form1.Name,cmbDown.Name)
End Sub
Sub sb_TextChanged
Msgbox (txt.Text)
End Sub
For #Develop :
Imports System.Windows.Forms
Imports System.Drawing
Public Class txtBox
Implements IDisposable 'Inherit from IDisposable if you need Basic4ppc to free resources when the application is closed.
Private WithEvents myControl As System.Windows.Forms.TextBox'The "real" object.
Public Event TextChanged As EventHandler 'The event handler name must match the event name.
Private eventObject() As Object 'One object[] for each event (one event here).
Sub New( ByVal frm as Form, ByVal txtBox As Control)
Dim ctrl As Windows.Forms.Control
For Each ctrl In frm.Controls
If (ctrl.Name = txtBox.Name) Then
eventObject = New Object() {Me, "TextChanged"}
AddHandler txtBox.TextChanged, AddressOf myControl_TextChanged
Exit Sub
End If
Next
msgbox ("Not Found")
End Sub
Private Sub myControl_TextChanged(ByVal sender As Object, ByVal e As EventArgs) Handles myControl.TextChanged
RaiseEvent TextChanged(eventObject, Nothing)
End Sub
Public Sub Dispose() Implements System.IDisposable.Dispose
If Not myControl Is Nothing Then
myControl.Dispose()
End If
End Sub
End Class
For Basic4PPC :
Sub App_Start
Form1.Show
sb.New1(Form1.Name,txt.Name)
sb.New1(Form1.Name,cmbDown.Name)
End Sub
Sub sb_TextChanged
Msgbox (txt.Text)
End Sub