i'm trying to write a program with C#. it should display ascii art. i tried to read in a ascii-art-file and display it in a textbox.
first problem, the encoding... it replaced the special chars with questionmarks, i solved this by using Encoding.Default. works well, if i save the text in the textbox back to a file and open it in windows editor everything is fine.
now my problem is: those special ascii chars (above 127) are not displayed correctly in the textbox. instead of a black box as it should be i get Os or Us and so on...
i already tried different fonts (Lucida Console, Lucida Console ASCII, MSI Console,...) but all with the same result Sad
i don't know how to fix this Sad any ideas


Re: Windows Forms General display ascii art in a textbox or richtextbox or whatever?


Use a StreamReader to read the file. Use one of the constructors that lets you set the encoding of the file. The encoding you pick must match the encoding that was used to write the file.