<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=windows-1250">


<META content="MSHTML 6.00.2900.2802" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=515352418-15122005><FONT face=Arial size=2>Sorry to send this 
here....and I prob.should send to OffTopic, but just incase someone who is not 
on the offtopic list knows the answer I am sending here.</FONT></SPAN></DIV>
<DIV><SPAN class=515352418-15122005><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=515352418-15122005><FONT face=Arial size=2>This is a .Net 
question that I asked lastnight 7pm but the email, infact no emails, has not 
comethru form the nz dotnet mailing list. If someone knows the answer, I would 
greatly appreciate the answer :-</FONT></SPAN></DIV>
<DIV><SPAN class=515352418-15122005><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=515352418-15122005>
<DIV><FONT face=Arial size=2><SPAN class=671095605-15122005>Hi 
all.</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=671095605-15122005>I fired up VS2005 
for the first time today...well first time to DO something....and I noticed the 
new SerialPort control.</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=671095605-15122005>This fitted in 
nicely because I want to read some data from the comport for the wee app I want 
to do.</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=671095605-15122005></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=671095605-15122005>Now I might be 
approching this the wrong way, but I dropped a serialport control onto my 
SmartDevice app....I am writting a PPC 2003 app. and set up the port settings 
etc, and on the "DataReceived" event I am doing :-</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=671095605-15122005></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial><SPAN class=671095605-15122005></SPAN></FONT><FONT 
size=2><SPAN class=671095605-15122005>&nbsp;&nbsp;&nbsp; </SPAN>TextBox1.Text = 
SerialPort1.ReadLine()</FONT></DIV>
<DIV><FONT size=2></FONT>&nbsp;</DIV>
<DIV><SPAN class=671095605-15122005><FONT size=2>And THIS is where it throws an 
error.&nbsp; Can someone please help?&nbsp;&nbsp; The error is 
:-</FONT></SPAN></DIV>
<DIV><SPAN class=671095605-15122005><FONT size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=671095605-15122005><FONT face=Arial 
size=2>System.NotSupportedException was unhandled<BR>&nbsp; 
Message="Control.Invoke must be used to interact with controls created on a 
separate thread."<BR>&nbsp; StackTrace:<BR>&nbsp;&nbsp;&nbsp; at 
Microsoft.AGL.Common.MISC.HandleAr()<BR>&nbsp;&nbsp;&nbsp; at 
System.Windows.Forms.Control.get_Text()<BR>&nbsp;&nbsp;&nbsp; at 
System.Windows.Forms.Control.set_Text()<BR>&nbsp;&nbsp;&nbsp; at 
DeviceApplication1.Form1.SerialPort1_DataReceived()<BR>&nbsp;&nbsp;&nbsp; at 
System.IO.Ports.SerialPort.CatchReceivedEvents()<BR>&nbsp;&nbsp;&nbsp; at 
EventLoopRunner.CallReceiveEvents()<BR>&nbsp;&nbsp;&nbsp; at 
WorkItem.doWork()<BR>&nbsp;&nbsp;&nbsp; at 
System.Threading.Timer.ring()<BR></FONT></SPAN></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><SPAN class=515352418-15122005><FONT face=Arial size=2>Thanks, 
Jeremy</FONT></SPAN></DIV></SPAN></DIV></BODY></HTML>
<BR>

<P><FONT SIZE=2>--<BR>
No virus found in this outgoing message.<BR>
Checked by AVG Free Edition.<BR>
Version: 7.1.371 / Virus Database: 267.13.13/200 - Release Date: 14/12/2005<BR>
</FONT> </P>