>
>
>Encoding windows1252Encoding = Encoding.GetEncoding(1252);
>
>
Ahh, GetEncoding is what I was overlooking. Thanks.
Kyle
You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.
Kyle Alons [mailto:[EMAIL PROTECTED]] wrote:
> I wish it were that simple, but it doesn't work. It writes a
> question mark char (ascii 0x3F) to the file. I originally
> looked at the ASCIIEncoding class, but the docs state that it
> only supports chars through 0x7F (7 bits). Any other ideas?
On Fri, 3 May 2002 13:21:35 -0400, Marsh, Drew <[EMAIL PROTECTED]> wrote:
>Kyle Alons [mailto:[EMAIL PROTECTED]] wrote:
>
>> What it writes to the file for the copyright character is
>> UTF-8 encoding (two bytes). What is the trick to get it to
>> write the single character 169 (copyright char i
Kyle Alons [mailto:[EMAIL PROTECTED]] wrote:
> What it writes to the file for the copyright character is
> UTF-8 encoding (two bytes). What is the trick to get it to
> write the single character 169 (copyright char in codepage
> 1252)? Thanks.
You need to go about creating your File and Stream
Given the following code:
string x = "Copyright © 1999";// contains copyright symbol, char 169
(0xA9)
StreamWriter f = File.CreateText(@"c:\t.out");
f.WriteLine(x);
f.Close();
What it writes to the file for the copyright character is UTF-8 encoding
(two bytes). What is the trick to get it t