Click here to Skip to main content
15,923,051 members
Home / Discussions / C#
   

C#

 
Questionupdating an exe in control panel Pin
Anil Kumar.Arvapalli9-Nov-10 16:26
Anil Kumar.Arvapalli9-Nov-10 16:26 
AnswerCrosspost warning! Pin
Peter_in_27809-Nov-10 16:35
professionalPeter_in_27809-Nov-10 16:35 
QuestionPing multiple IP adresses Pin
peropata9-Nov-10 9:36
peropata9-Nov-10 9:36 
AnswerRe: Ping multiple IP adresses Pin
Luc Pattyn9-Nov-10 10:08
sitebuilderLuc Pattyn9-Nov-10 10:08 
GeneralRe: Ping multiple IP adresses Pin
peropata9-Nov-10 11:18
peropata9-Nov-10 11:18 
GeneralRe: Ping multiple IP adresses Pin
Luc Pattyn9-Nov-10 11:24
sitebuilderLuc Pattyn9-Nov-10 11:24 
GeneralRe: Ping multiple IP adresses Pin
peropata9-Nov-10 11:49
peropata9-Nov-10 11:49 
GeneralRe: Ping multiple IP adresses Pin
Mycroft Holmes9-Nov-10 12:10
professionalMycroft Holmes9-Nov-10 12:10 
QuestionGenerate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed [modified] Pin
tschueggi9-Nov-10 3:08
tschueggi9-Nov-10 3:08 
AnswerRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
Luc Pattyn9-Nov-10 4:08
sitebuilderLuc Pattyn9-Nov-10 4:08 
GeneralRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
tschueggi9-Nov-10 5:30
tschueggi9-Nov-10 5:30 
GeneralRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
Luc Pattyn9-Nov-10 6:29
sitebuilderLuc Pattyn9-Nov-10 6:29 
GeneralRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
tschueggi10-Nov-10 2:13
tschueggi10-Nov-10 2:13 
AnswerRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
_Erik_10-Nov-10 1:58
_Erik_10-Nov-10 1:58 
GeneralRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
tschueggi10-Nov-10 2:20
tschueggi10-Nov-10 2:20 
GeneralRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
_Erik_10-Nov-10 2:52
_Erik_10-Nov-10 2:52 
GeneralRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
tschueggi10-Nov-10 4:42
tschueggi10-Nov-10 4:42 
GeneralRe: Generate Word Report fails with System.Runtime.InteropServices.COMException (0x800A1066): Command Failed Pin
_Erik_10-Nov-10 7:12
_Erik_10-Nov-10 7:12 
QuestionHelp with serial data display Pin
turbosupramk39-Nov-10 1:58
turbosupramk39-Nov-10 1:58 
AnswerRe: Help with serial data display Pin
OriginalGriff9-Nov-10 2:17
mveOriginalGriff9-Nov-10 2:17 
GeneralRe: Help with serial data display Pin
turbosupramk39-Nov-10 2:26
turbosupramk39-Nov-10 2:26 
GeneralRe: Help with serial data display Pin
OriginalGriff9-Nov-10 4:21
mveOriginalGriff9-Nov-10 4:21 
The first thing which springs to mind is:

Don't read the text into a string and invoke a routine to handle it. The only logical reason for doing that is to get the execution onto the GUI thread - which may not execute it immediately. If a single other character arrives in the mean time, it will discard your existing data. Better to get the data in the invoked method instead, or add it to a queue (my preference).

Regarding your problem with new lines: Are you sure you are receiving them? Remember that ReadExisting translates according tgo the encoding (Strings are generally Unicode, serial ports are generally ASCII). I would be tempted to either try using ReadLine instead of ReadExisting, or ReadAllBytes and display the data as Hex, at least in the early stages.

I also wouldn't want to use a TextBox - a ListBox might be better as it doesn't slow down lots when the strings start to get large.
Real men don't use instructions. They are only the manufacturers opinion on how to put the thing together.

GeneralRe: Help with serial data display Pin
turbosupramk39-Nov-10 6:38
turbosupramk39-Nov-10 6:38 
GeneralRe: Help with serial data display Pin
OriginalGriff9-Nov-10 8:21
mveOriginalGriff9-Nov-10 8:21 
GeneralRe: Help with serial data display Pin
ColinBurnell9-Nov-10 21:41
professionalColinBurnell9-Nov-10 21:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.