随笔分类 -  C#

C#
摘要:在main中调用 示例二 阅读全文
posted @ 2018-07-18 11:33 恋上微笑的天使 阅读(311) 评论(0) 推荐(0)
摘要:public DataSet TransExcelToDataSet(string fileName, List sheetNames) { OleDbConnection objConn =null; DataSet data =new DataSet(); //创建读取excel连接 ... 阅读全文
posted @ 2018-07-18 11:31 恋上微笑的天使 阅读(897) 评论(0) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2018-07-02 17:26 恋上微笑的天使 阅读(6) 评论(0) 推荐(0)
摘要:在JS中将JSON的字符串解析成JSON数据格式,一般有两种方式:1. 一种为使用eval()函数。2. 使用Function对象来进行返回解析 一、使用eval()函数 系统后台代码 eval解析 JS解析Json 数组 二、解析json数组即对JSONArray的遍历 2.1、对于标准的json 阅读全文
posted @ 2018-06-26 10:10 恋上微笑的天使 阅读(879) 评论(0) 推荐(0)
摘要:在作应用系统开发时,管理配置是必不可少的。例如数据库服务器的配置、安装和更新配置等等。由于Xml的兴起,现在的配置文件大都是以xml文档来存储。比如Visual Studio.Net自身的配置文件Mashine.config,Asp.Net的配置文件Web.Config,包括我在介绍Remoting 阅读全文
posted @ 2018-05-31 10:07 恋上微笑的天使 阅读(259) 评论(0) 推荐(0)
该文被密码保护。
posted @ 2018-05-17 09:27 恋上微笑的天使 阅读(1) 评论(0) 推荐(0)
摘要:查询语句 selectdb.SHAPE.SDO_gtype as SDO_gtype, db.shape.sdo_srid as sdo_srid, db.shape.sdo_point.x as point_x, db.shape.sdo_point.y as point_y, db.shape. 阅读全文
posted @ 2018-04-17 09:06 恋上微笑的天使 阅读(1055) 评论(0) 推荐(0)
摘要:将word内容追击到新建WORD文档 阅读全文
posted @ 2017-09-30 11:35 恋上微笑的天使 阅读(420) 评论(0) 推荐(0)
摘要:最近在做一个程序,需要在程序中对Word内容做些处理。从网上查了很多资料,发现,许多都是重复的。更有许多知识,根本没有讲到。为了以后使用方便。将所有的这些知识,加以总结,以备后来人使用。 1、引用 需要引用 COM库:Microsoft word 11.0 Object Library. 不同的版本 阅读全文
posted @ 2017-09-30 08:55 恋上微笑的天使 阅读(2382) 评论(1) 推荐(1)
摘要:public partial class BaseForm : Form { private Timer timer; int x, y; DateTime start; bool ff = true; public BaseForm() { timer =... 阅读全文
posted @ 2017-08-19 09:23 恋上微笑的天使 阅读(1407) 评论(0) 推荐(0)
摘要:#region 移除数组中重复数据 /// /// 移除数组中重复数据 /// /// 需要除重的数组 /// 不重复数组 public static string[] DelRepeatData(string[] array) { return ar... 阅读全文
posted @ 2017-07-03 11:45 恋上微笑的天使 阅读(332) 评论(0) 推荐(0)
摘要:Excel文件导入导出,需引用Microsoft Excel 11.0 Object Library 阅读全文
posted @ 2017-03-27 13:55 恋上微笑的天使 阅读(3136) 评论(0) 推荐(0)
摘要:1、当dataset中包含了html等特殊字符用这个处理 2. 3. 阅读全文
posted @ 2017-03-27 13:49 恋上微笑的天使 阅读(684) 评论(0) 推荐(0)
摘要://获取当天的数据 DrawRecordDA _recordDA = new DrawRecordDA(); var query = _recordDA.GetQuery(); //筛选 当天 //query = query.Where(q=>SqlFunctions.Dat... 阅读全文
posted @ 2016-11-23 11:23 恋上微笑的天使 阅读(2390) 评论(0) 推荐(1)
摘要:protected void btnUpload_Click(object sender, EventArgs e) { HttpFileCollection Files = HttpContext.Current.Request.Files; for (int i = 0; i 0) ... 阅读全文
posted @ 2016-11-14 16:40 恋上微笑的天使 阅读(145) 评论(0) 推荐(0)
摘要:private static string GetMD5HashFromFile(string fileName) { try { FileStream file = new FileStream(fileName, FileMode.Open); Sy... 阅读全文
posted @ 2016-09-13 17:00 恋上微笑的天使 阅读(252) 评论(0) 推荐(0)
摘要:System.Data.OleDb; //导入名空间 private Button1_Click(object sender,System.EventArgs e) { if(TextBox1.Text.ToString().Trim()!=""||TextBox1.Text.ToString().Trim()!=String.Empty()) { OleDbCo... 阅读全文
posted @ 2016-06-15 10:57 恋上微笑的天使 阅读(215) 评论(0) 推荐(0)
摘要:SqlConnection conn = new SqlConnection("uid=sa;pwd=*;database=login;server=server"); SqlCommand myCom = conn.CreateCommand(); myCom.CommandType = CommandType.Text; if(txtB_user.Text.Leng... 阅读全文
posted @ 2016-06-15 10:53 恋上微笑的天使 阅读(220) 评论(0) 推荐(0)
摘要:string password = txtPassword.Text.ToString(); string name = txtUserName.SelectedItem.ToString(); string connecitonString = "server=(local);" + "intetrated securi... 阅读全文
posted @ 2016-06-15 10:52 恋上微笑的天使 阅读(177) 评论(0) 推荐(0)
摘要:获取XML文件 解析XML 阅读全文
posted @ 2016-05-27 13:42 恋上微笑的天使 阅读(201) 评论(0) 推荐(0)