Re: Console.WriteLine(s) Is Missing Line Terminator?
- From: Gadget <gadget@xxxxxxxxxx>
- Date: Sat, 18 Nov 2006 09:45:24 +1100
On Fri, 17 Nov 2006 21:46:44 +0100, Mattias Sjögren wrote:
1) Level is missing from the output - It only contains InfoString. For
instance: When Level = "INFO", and InforString = "Process started", The
output is "Process started" only;
2) No newline character at the end.
Any advice on what it going on and how to get this resolved? Thanks!
Can you post a small complete application that will let us reproduce
the behaviour you're seeing? Console.WriteLine has always worked fine
here so I suspect your input is incorrect.
Mattias
Also as a rule of thumb, avoid using '&' to concatenate strings, as it has
a tendency to hide casting errors. It's only in there for VB6 style
compatibility, and should be burned at the stake along with Option Explicit
Off :)
Try placing a breakpoint on the Console.WriteLine statement and see what
the variable 's' contains. Perhaps you're passing control characters on the
end?
Cheers,
Gadget
.
- Follow-Ups:
- Re: Console.WriteLine(s) Is Missing Line Terminator?
- From: Mattias Sjögren
- Re: Console.WriteLine(s) Is Missing Line Terminator?
- References:
- Console.WriteLine(s) Is Missing Line Terminator?
- From: Fir5tSight
- Re: Console.WriteLine(s) Is Missing Line Terminator?
- From: Mattias Sjögren
- Console.WriteLine(s) Is Missing Line Terminator?
- Prev by Date: Re: Use reflection to find out property name?
- Next by Date: Re: textbox and size.
- Previous by thread: Re: Console.WriteLine(s) Is Missing Line Terminator?
- Next by thread: Re: Console.WriteLine(s) Is Missing Line Terminator?
- Index(es):
Relevant Pages
|
Loading