Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27349

VS 2010 Update TextBox from Backgroundworker in Module

$
0
0
How to update TextBox from Background which placed in module? I wrote something like this in my module:
Code:

Private Sub BackgroundWorker1DoWork(sender As System.Object, e As System.ComponentModel.DoWorkEventArgs) Handles BackgroundWorker1.DoWork
        If (Form1.IsHandleCreated = True) Then
          Form1.Invoke(New MethodInvoker(Sub()
                              Form1.TextBox49.Text = "test"
                              End Sub))
        End If)
End Sub

But condition "IsHandleCreated" is always false despite my Form is loaded.

Viewing all articles
Browse latest Browse all 27349

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>