[Mono-list] mcs use codepage and program with chinese

ffffb8ffffb8 ffffbfffffe4 kuafftek@yahoo.com.cn
Tue, 10 Aug 2004 12:09:16 +0800 (CST)


--0-100382177-1092110956=:10143
Content-Type: text/plain; charset=gb2312
Content-Transfer-Encoding: 8bit


If you are a East-Aisa prople,maybe you will find them.Now let's test and write a program with East-Aisa language.using System;namespace Test{   public class Hello   {     public static void Main()     {         Console.WriteLine("");     }   }  }______________It is a simple problem Like "Hello world", but use chinese.In Windows(Language Chinese,codepage:936, GB2312),run"mcs -codepage:936 Hello.cs",then get Hello.exe.When We run the Hello.exe,In Console It don't show "",butsome strange characters.In linux as same.Now we test the program in another mode.We use the tool "native2ascii" of JDK and run "native2ascii Hello.cshello1.cs",then we get Hello1.cs in ascii coding.run "mcs -codepage:utf8 Hello1.cs" ,then get Hello1.ex.Run hello1.exe,In windows we get right output "";but in Linux it output some strange characters.Strange?




---------------------------------
Do You Yahoo!?
150MP3ѣֵ
ŮӦоУѱͼͼͿͼ
1G1000ףŻݣ
--0-100382177-1092110956=:10143
Content-Type: text/html; charset=gb2312
Content-Transfer-Encoding: 8bit

<PRE>If you are a East-Aisa prople,maybe you will find them.

Now let's test and write a program with East-Aisa language.

using System;
namespace Test
{
   public class Hello
   {
     public static void Main()
     {
         Console.WriteLine("");
     }
   }  
}

______________
It is a simple problem Like "Hello world", but use chinese.

In Windows(Language Chinese,codepage:936, GB2312),run
"mcs -codepage:936 Hello.cs",then get Hello.exe.

When We run the Hello.exe,In Console It don't show "",but
some strange characters.

In linux as same.

Now we test the program in another mode.

We use the tool "native2ascii" of JDK and run "native2ascii Hello.cs
hello1.cs",then we get Hello1.cs in ascii coding.

run "mcs -codepage:utf8 Hello1.cs" ,then get Hello1.ex.Run hello1.exe,
In windows we get right output "";

but in Linux it output some strange characters.


Strange?
</PRE>
<DIV></DIV><p><br><hr size=1><b>Do You Yahoo!?</b><br>
<a href="http://music.yisou.com" target=blank>150MP3ѣֵ</a><br><a href="http://image.yisou.com" target=blank>ŮӦоУѱͼͼͿͼ</a><br>
<a href="http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event/mail_1g/" target=blank>1G1000ףŻݣ</a>
--0-100382177-1092110956=:10143--