How can I access a control from a thread other than the thread it was created on, avoiding the cross-thread error?
Here is my sample code for this:
private void Form1_Load(object sender, EventArgs e)
{
Thread t = new Thread(foo);
t.Start();
}
private void foo()
{
this.Text = "Test";
}