随笔分类 -  c#

摘要:目录 1、窗体(Form) 2、Label (标签)控件 3、TextBox(文本框)控件 4、RichTextBox控件 5、NumericUpDown控件 6、Button(按钮)控件 7、GroupBox(分组框)控件 8、RadioButton(单选按钮)控件 9、CheckBox(复选框) 阅读全文
posted @ 2018-04-20 14:48 成小伟 阅读(2952) 评论(0) 推荐(0) 编辑
摘要:public string UploadFile(string filePath, string fileName, string ftpServerIP, string ftpUserName, string ftpPassword) { string file = filePath + file 阅读全文
posted @ 2017-01-23 13:16 成小伟 阅读(3763) 评论(0) 推荐(0) 编辑
摘要:DirectoryInfo directory = new DirectoryInfo(@"D:\0001\" + year + @"\" + time.Substring(4,2) + @"\" + LocaleId + @"\"); if (!directory.Exists)//不存在 dir 阅读全文
posted @ 2017-01-23 13:15 成小伟 阅读(6621) 评论(0) 推荐(0) 编辑
摘要:private DataTable ToDataTable(DataRow[] rows) { if (rows == null || rows.Length == 0) return null; DataTable tmp = rows[0].Table.Clone(); // 复制DataRow 阅读全文
posted @ 2016-08-29 10:14 成小伟 阅读(27375) 评论(0) 推荐(0) 编辑
摘要:dtTemp.Columns.Add("列名");//增加一列 dtTemp.Columns.Remove("列名");//删除一列 dtTemp.Columns["旧列名"].ColumnName = "新列名";//修改列名 dtTemp.Columns["列名1"].SetOrdinal(dt 阅读全文
posted @ 2016-07-08 15:52 成小伟 阅读(428) 评论(0) 推荐(0) 编辑
摘要:1、表现层(UI):通俗讲就是展现给用户的界面,即用户在使用一个系统的时候他的所见所得。 2、业务逻辑层(BLL):针对具体问题的操作,也可以说是对数据层的操作,对数据业务逻辑处理。 3、数据访问层(DAL):该层所做事务直接操作数据库,针对数据的增、删、改、查。 在软件体系架构设计中,分层式结构是 阅读全文
posted @ 2015-11-18 08:50 成小伟 阅读(323) 评论(0) 推荐(0) 编辑
摘要:string file = @"E:\Tra.xls"; OleDbConnection conn = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + file + ";Extended Pr... 阅读全文
posted @ 2015-11-02 15:36 成小伟 阅读(133) 评论(0) 推荐(0) 编辑
摘要:table:表dataName:文件名listNme:列名public void RenderToExcel(DataTable table, string dataName, string[] listNme) { var countL = listNme.Le... 阅读全文
posted @ 2015-06-24 11:23 成小伟 阅读(181) 评论(0) 推荐(0) 编辑
摘要:int[] arry;arry=new int[n]{1,2,3,4....} 阅读全文
posted @ 2014-12-09 16:03 成小伟 阅读(204) 评论(0) 推荐(0) 编辑