摘要:
/// <summary> /// 将存贮在文本文件中的数据绑定到DropDownList中 test,test /// </summary> /// <param name="drdlst">下拉菜单</param> /// <param name="filePath">虚拟路径</param> public void Dr... 阅读全文
posted @ 2010-06-22 17:58
liufei
阅读(132)
评论(0)
推荐(0)
摘要:
在网上找了很多资料,最后通过调试,读取项目名称功能是实现了,具体的优化暂时没时间去弄值得注意的是,页面在返回即刷新的时候要预处理清空下comboBox的值,否则会引起重复this.combox.Items.Clear();代码如下:view plaincopy to clipboardprint?/// <summary> /// 从txt文件中得到项目名称,再显示到comboBox... 阅读全文
posted @ 2010-06-22 17:57
liufei
阅读(2292)
评论(0)
推荐(1)
摘要:
usingSystem; usingSystem.IO; usingSystem.Runtime.Serialization.Formatters.Binary; usingSystem.Runtime.Serialization.Formatters.Soap; usingSystem.Runtime.Serialization.Json; usingSystem.Text; usingSyst... 阅读全文
posted @ 2010-06-22 14:41
liufei
阅读(492)
评论(0)
推荐(0)
摘要:
里面用到了TreeView,数据有1500多条,加载要10秒钟左右 柳永法(yongfa365)'Blog的特点是:有问题,就要解决,尤其是像这种几十人、上百人使用的系统。后来使用登录时加载数据,登录后再使用就Clone()的解决方案,感觉不错。不过,每次调试程序时得等半天,实在不爽。前些天看到“序列化”这个概念,大意就是把对象保存为一个文件,下次再使用时,反序列化一下就O... 阅读全文
posted @ 2010-06-22 14:40
liufei
阅读(822)
评论(0)
推荐(0)
摘要:
网上有很多方案,起初用时,因为对asp.net不太了解,觉得FTP实现不错,可是后来发现,如果机器在域控下,就会有问题。一年过去了,asp.net也熟悉了,知道ajax没事应该用ashx,验证码也用ashx,当然这里要说的WinForm上传也应该是ashx了吧,哈哈,先提供简单思路:接收文件的asp.net是:Uploader.ashx,相关代码:view plaincopy to clipboa... 阅读全文
posted @ 2010-06-22 14:37
liufei
阅读(1778)
评论(0)
推荐(0)
摘要:
view plaincopy to clipboardprint?usingSystem; usingSystem.Data; usingSystem.Configuration; usingSystem.Web; usingSystem.Web.Security; usingSystem.Web.UI; usingSystem.Web.UI.WebControls; usingSystem.We... 阅读全文
posted @ 2010-06-22 14:34
liufei
阅读(392)
评论(0)
推荐(0)
摘要:
XmlDocumentxmlDoc=newXmlDocument(); xmlDoc.Load("bookstore.xml"); //xmlDoc.LoadXml("<!--lversion=\"1.0\"encoding=\"gb2312\--><BOOKSTORE></BOOKSTORE>"); XmlNoderoot=xmlDoc.SelectSingl... 阅读全文
posted @ 2010-06-22 14:33
liufei
阅读(204)
评论(0)
推荐(0)
摘要:
//需要添加System.Drawing及System.Windows.Forms引用 usingSystem; usingSystem.Drawing; usingSystem.Drawing.Drawing2D; usingSystem.Drawing.Imaging; usingSystem.Windows.Forms; namespace网页截图 { classProgram { [STA... 阅读全文
posted @ 2010-06-22 14:32
liufei
阅读(566)
评论(1)
推荐(0)
摘要:
usingSystem; usingSystem.Collections.Generic; //int[]到string[]的转换 publicclassExample { staticvoidMain() { int[]int_array={1,2,3}; string[]str_array=Array.ConvertAll(int_array,newConverter<int,strin... 阅读全文
posted @ 2010-06-22 14:31
liufei
阅读(839)
评论(0)
推荐(0)
摘要:
//服务器重启服务,作者:柳永法 www.yongfa365.comusing System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Diagnostics;using System.ServiceProcess;using System.IO;using... 阅读全文
posted @ 2010-06-22 14:31
liufei
阅读(412)
评论(0)
推荐(0)
摘要:
publicclassListItem { privatestring_key=string.Empty; privatestring_value=string.Empty; publicListItem(stringpKey,stringpValue) { _key=pKey; _value=pValue; } publicoverridestringToString() { returnthi... 阅读全文
posted @ 2010-06-22 14:30
liufei
阅读(251)
评论(0)
推荐(0)