I have created a porcess that manipulates large volumes of text. I have created a form that has a button that manually starts the process. I have tried to give some feedback that the process is actually progressing through the data by changing the value of text fields on the form. However the text fields do not update on the form until after the process is complete. I had this working in another program but cannot figure out what I am doing different. I use the following code to change the text.

[ Form2.Label2.Text = "Started"
Call Main()
Form2.Label1.Text = "SComplete"

7 Years
Discussion Span
Last Post by jonniebl

For the example I'll assume that Form2 is created using
Dim Form2 as New frmMyForm
being frmMyForm the class for the form being used

Then I will suggest to change the definition of sub Main as:

Sub Main(ByRef FormToUpdate as frmMyFomr)

Then inside the sub Main you can

FormToUpdate.Label2.Text = "I've prcessed a bit"

Hope this helps

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.