I have created a C# application that creates a UTF-8 encoded text file (*.txt). It creates this file which when opened in Notepad displays correctly…however, when I open the file in Notepad++ the file has additional carriage returns and blank lines within it.
Has anyone come accross this type of formatting discrepancy before, is there a specific encoding I should be using to ensure correct display within Notepad++ ?
For reference, all development and checking is taking place on Windows (7 sp1).
I suggest for you to use:
View --> Show Symbol --> Show End of Line
Or even an hex editor if you have one available.
My guess is that your C# app generates something like [CR][LF][LF] which Notepad interprets as a single end-of-line of type [CR][LF] but NP++ interpret as 2 end-of-lines of type [LF].
Thanks, I’ll give it a look.
@gstavi Yes that was spot on…my text manipulation was looking at \r [CR] when all it needed was to llok at \n [LF] first instead ! Thanks :)