摘要:using System; using System.IO; using System.IO.Compression; using System.Security.Cryptography; using System.Text; static void Main(string[] args) { D 阅读全文
posted @ 2020-06-05 17:32 Fred1987 阅读(6) 评论(0) 推荐(0) 编辑
摘要:static void BinaryWriterReaderDemo() { using (FileStream fs = new FileStream("fs.txt", FileMode.Create)) { SaveData(fs); } using(FileStream fs=new Fil 阅读全文
posted @ 2020-06-05 14:48 Fred1987 阅读(30) 评论(0) 推荐(0) 编辑
摘要:static void FileStreamWriterReadDemo() { string textFile = "fs.txt"; using (FileStream fs = new FileStream(textFile, FileMode.Create)) { using (Stream 阅读全文
posted @ 2020-06-04 12:05 Fred1987 阅读(5) 评论(0) 推荐(0) 编辑
摘要:using System.Globalization; static void GetCultureInfos() { var cultures = CultureInfo.GetCultures(CultureTypes.AllCultures).OrderBy(x => x.Name).ToLi 阅读全文
posted @ 2020-06-03 15:11 Fred1987 阅读(9) 评论(0) 推荐(0) 编辑
摘要:Named pipe (more flexible)Allows two-way communication between arbitrary processes on the same computer or different computers across a network.A pipe 阅读全文
posted @ 2020-06-02 11:13 Fred1987 阅读(36) 评论(0) 推荐(0) 编辑
摘要:static void FileStreamSDemo() { DateTime dtNow = DateTime.Now; DateTime dtEnd = dtNow.AddSeconds(60); using(FileStream fs=new FileStream("FileStream.t 阅读全文
posted @ 2020-06-01 21:57 Fred1987 阅读(34) 评论(0) 推荐(0) 编辑
摘要:static void Main(string[] args) { A(); Console.ReadLine(); } static void A() { B(); } static void B() { C(); } static void C() { StackTrace s = new St 阅读全文
posted @ 2020-06-01 14:40 Fred1987 阅读(8) 评论(0) 推荐(0) 编辑
摘要:static void Main(string[] args) { DoWorkProxy(); Console.ReadLine(); } [DebuggerStepThrough,DebuggerHidden] static void DoWorkProxy() { PrintTime(); } 阅读全文
posted @ 2020-06-01 11:10 Fred1987 阅读(7) 评论(0) 推荐(0) 编辑
摘要:static void ListTimeZoneInfos() { StringBuilder timeBuilder = new StringBuilder(); var timeZoneInfoList = TimeZoneInfo.GetSystemTimeZones().OrderBy(x= 阅读全文
posted @ 2020-05-31 21:24 Fred1987 阅读(7) 评论(0) 推荐(0) 编辑
摘要:string inputStr = "'some string'"; string outputStr = inputStr.Trim(new char[]{(char)39}); 阅读全文
posted @ 2020-05-27 20:59 Fred1987 阅读(9) 评论(0) 推荐(0) 编辑