摘要: /// /// 验证是否为纯数字 /// /// /// public static bool IsNumeric(string str) { if (str == null || str.Length == 0) return fals... 阅读全文
posted @ 2017-08-22 15:07 孤夏 阅读(943) 评论(0) 推荐(0) 编辑
摘要: DataTable dt = (DataTable)dgv.DataSource; dt.Rows.Clear(); dgv.DataSource = dt; 阅读全文
posted @ 2017-08-22 15:03 孤夏 阅读(124) 评论(0) 推荐(0) 编辑
摘要: OpenFileDialog openFileDialog = new OpenFileDialog(); openFileDialog.Filter = "Microsoft Excel files(*.xls)|*.xls;*.xlsx";//过滤一下,只要表格格式的 openFileDialog.InitialDirectory = "c:\... 阅读全文
posted @ 2017-08-22 15:03 孤夏 阅读(385) 评论(0) 推荐(0) 编辑