Bonzay0
05-19-2009, 03:11 PM
I'am tring to change a textbox from another class
but the text box isn't changing why is that?
here is a piece of the code:
in the class:
Public Class Chat
Private Sub SendB_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles SendB.Click
Dim x As New tee
x.startBackgroundTask()
Me.Logtxt.Text += "Whoopy" + vbCrLf
End Sub
End Class
in the other class:
Public Class tee
Private Sub BackgroundWorker1_DoWork(ByVal sender As Object, _
ByVal e As System.ComponentModel.DoWorkEventArgs) Handles BackgroundWorker1.DoWork
Chat.Logtxt.Text += "YEY"
End Sub
End Classhelp plz
but the text box isn't changing why is that?
here is a piece of the code:
in the class:
Public Class Chat
Private Sub SendB_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles SendB.Click
Dim x As New tee
x.startBackgroundTask()
Me.Logtxt.Text += "Whoopy" + vbCrLf
End Sub
End Class
in the other class:
Public Class tee
Private Sub BackgroundWorker1_DoWork(ByVal sender As Object, _
ByVal e As System.ComponentModel.DoWorkEventArgs) Handles BackgroundWorker1.DoWork
Chat.Logtxt.Text += "YEY"
End Sub
End Classhelp plz