using System;
using System
using System
using System
//big
public class EncodeTool
{
[DllImport(
public static extern int LCMapString(int Locale
const int LCMAP_SIMPLIFIED_CHINESE =
const int LCMAP_TRADITIONAL_CHINESE =
public static void Main (String[] args)
{
if (args
{
Console
}
String[] files=Directory
if(args
files=Directory
String dir=args[
if(!Directory
Directory
}
for(int i=
String lines=sr
sr
lines=ConvertString(lines);
//Console
StreamWriter sw = new StreamWriter(dir+
sw
sw
Console
}
}
public static String ConvertString(String lines){
Encoding gb
byte[] src=gb
byte[] dest = new byte[src
LCMapString(
return gb
}
}
From:http://tw.wingwit.com/Article/program/net/201311/15082.html