摘要: private string GetWeek() { string week = string.Empty; switch ((int)DateTime.Now.DayOfWeek) { case 0: week = "星期日";... 阅读全文
posted @ 2019-08-13 11:09 饮木 阅读(10990) 评论(0) 推荐(1) 编辑
摘要: private void aa() { System.Drawing.Printing.PrintDocument print = new System.Drawing.Printing.PrintDocument(); string sDefault = print.PrinterSettings.PrinterName;//默认... 阅读全文
posted @ 2019-07-30 09:22 饮木 阅读(2463) 评论(0) 推荐(0) 编辑
摘要: static void Main(string[] args) { string filePath = @"e:\test\abc.jpg"; Console.WriteLine(Path.GetFullPath(filePath)); //--> E:\test\abc.jpg Console.Wri... 阅读全文
posted @ 2019-07-22 20:39 饮木 阅读(10922) 评论(0) 推荐(1) 编辑
摘要: 第一种: 第二种: 阅读全文
posted @ 2019-07-22 20:28 饮木 阅读(106996) 评论(8) 推荐(4) 编辑
摘要: for /l %%i in (1,1,10) do @echo %%ipause 阅读全文
posted @ 2019-07-17 14:27 饮木 阅读(1695) 评论(0) 推荐(0) 编辑
摘要: /// /// 获得pc号 /// public static string GetPcsnString() { var pcsn = ""; try { var search = new Manage... 阅读全文
posted @ 2019-06-24 16:59 饮木 阅读(706) 评论(0) 推荐(0) 编辑
摘要: 1、增加字段(修改表)alter table 表名 ADD 字段 类型 NOT NULL Default 0 阅读全文
posted @ 2019-06-24 11:50 饮木 阅读(137) 评论(0) 推荐(0) 编辑
摘要: string l_strResult = 你的字符串.Replace("\n", "").Replace(" ","").Replace("\t","").Replace("\r",""); 阅读全文
posted @ 2019-06-24 11:49 饮木 阅读(15234) 评论(0) 推荐(1) 编辑
摘要: string数组 string[] s1 = new string[3] { "John", "Paul", "Mary" }; string[] s1 = new string[3] { "John", "Paul", "Mary" }; if (s1.Contains("John")) if ( 阅读全文
posted @ 2019-06-24 10:48 饮木 阅读(2696) 评论(0) 推荐(0) 编辑
摘要: i.ToString().PadLeft(5,'0'); 阅读全文
posted @ 2019-06-13 10:34 饮木 阅读(220) 评论(0) 推荐(0) 编辑