I downloaded the Visual C# express, which includes the .NET Framework 2.0.
The following exception is generated:
{"Illegal cross-thread operation: Control 'textBox1' accessed from a
thread other than the thread it was created on."}
on the following code:
namespace WindowsApplication1
{
partial class Form1 : Form
{
//private string buffer;
public Form1()
{
InitializeComponent();
this.serialPort1.Open();
if (this.serialPort1.IsOpen)
this.textBox1.AppendText("Port opened successfully");
}
private void serialPort1_ReceivedEvent(object sender,
System.IO.Ports.SerialReceivedEventArgs e)
{
this.textBox1.AppendText(this.serialPort1.ReadExis ting()); ;
}
}
}
Both SerialPort and TextBox object are dragged from the Toolbox in
Visual C# 2005 Express Beta.
Alex