title: C# Get Textbox value in backgroundworker dowork event
body: <p>In my windows forms application I have a <code>textbox</code> and <code>backgroundworker</code> component. In <code>dowork</code> event of the <code>backgroundworker</code> I am trying to access value of the textbox. How can i do that? I'm getting following exception in dowork event handler code when I try to access value of the textbox:</p>
  
  <pre><code>Cross-thread operation not valid: Control 'txtFolderName' accessed from a thread other than the thread it was created on`
  </code></pre>