Autor Beitrag
stugi82
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 33



BeitragVerfasst: Mo 04.08.08 20:32 
Hallo,

wie kann ich denn beim schreiben eines txt-Files mit einem StreamWriter einstellen, in welcher Codierung (UNIX oder Dos\Windows) das File erzeugt wird.
Ich habe da ein Problem, dass mein Programm das nicht immer einheitlich handelt.

Danke!
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Mo 04.08.08 20:36 
Hallo!

Der StreamWriter hat verschiedene Konstruktoren, bei denen man auch den Encoding-Parameter hat.

Eigentlich sollte per Default aber immer dasselbe Encoding verwendet werden :gruebel:

Grüße
Christian

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".