Cannot update UI from other task in win forms? <p>I have four complex tasks running parallel, I want to update a rich textbox with the log file. The approximate program structure is as follows:</p> <pre><code>Sub buttonClick () complextask1 'code goes here complextask2 'code goes here complextask3 'code goes here complextask4 'code goes here end sub </code></pre> <p>The above four tasks updates a log file, which I have to display in a <code>RichTextbox</code> control. I tried with an infinite <code>while</code> loop, and updating the <code>textbox</code>, but my <code>UI</code> is getting hanged.</p>