标签:
string src = "abcd1234"; byte[] types=Encoding.Default.GetBytes(src); string dest= Encoding.Default.GetString(types);
byte[] pubArray = AssemblyTextReader.Read("NS.AssemblyName.dir1.subdir.file");
System.Reflection.Assembly assembly = System.Reflection.Assembly.GetExecutingAssembly(); Stream ms = assembly.GetManifestResourceStream("NS.AssemblyName.dir1.subdir.file");
byte[] bytes=.... MemoryStream ms = new MemoryStream(bytes); byte[] dst=ms.toArray();
FileStream steram=new FileStream("file.txt",FileMode.Create); BinaryWriter bw = new BinaryWriter(stream); bw.Write(bytes)
string base64str=Convert.ToBase64String(byte[] bytes); byte[] bytes=Convert.FromBase64String(base64str);
标签:
原文地址:http://www.cnblogs.com/pixy/p/4970476.html