摘要:
自定义创建web验证控件做Asp.net开发的都知道在VS里提供了很多的验证控件,比如:RequiredFieldValidator, RangeValidator,RegularExpressionValidator等等,他们都是继承于BaseValidator这个基类,BaseValidator类是一个抽象(abstract)类,它要求子类必须实现一个方法:EvaluateIsValid...
阅读全文
posted @ 2010-06-02 15:18
KimhillZhang
阅读(411)
推荐(0)
摘要:
如果要在.ashx(一般处理程序) 中使用Session如果不改一些信息的话直接使用context.Session[“uid”]这样会出现“未将对象引用设置到对象实例”就是说值为null。此时的解决办法就是:1、在命名空间里导入:using System.Web.SessionState;2、让它继承接口IRequiresSessionState:p...
阅读全文
posted @ 2010-06-01 15:09
KimhillZhang
阅读(1311)
推荐(0)
摘要:
using System;using System.Collections.Generic;using System.Text;using System.Net;using System.IO;namespace TestWebClientClass{ class Program { static void Main(string[] args) { WebClient client = new ...
阅读全文
posted @ 2010-05-29 10:36
KimhillZhang
阅读(287)
推荐(0)
摘要:
using System;using System.Collections.Generic;using System.Text;using System.IO;namespace StreamReader类{ class Program { //static void Main(string[] args) //{ //} public static void Main() { string pa...
阅读全文
posted @ 2010-05-29 10:35
KimhillZhang
阅读(448)
推荐(0)
摘要:
使用 System.IO 和 Visual C# .NET 读取文本文件在 Visual C# .NET 中读取文本文件 打开和读取文件进行读取访问是输入/输出 (IO) 功能的一个非常重要的部分,即使您不需要写入到相关文件,也是如此http://www.alixixi.com/Dev/Web/ASPNET/aspnet3/2007/2007050734418.html确保项目至少引用了 Syst...
阅读全文
posted @ 2010-05-29 10:31
KimhillZhang
阅读(1339)
推荐(0)
摘要:
using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConsoleApplication2{ public class Program { public static void Main() { testTime t = new testTime(); string ...
阅读全文
posted @ 2010-05-25 17:27
KimhillZhang
阅读(386)
推荐(0)
摘要:
今天有一个需求需要进行以“;”和“,”为分割符把数据分隔开,然后再插入数据库里,用存储过程实现;如字符串为:kimhillzhang,20;jinshanzhang,25,现在要以kimhillzhang 20 为一条数据插入数据库,以jinshanzhang 25为一条数据插入数据库name agekimhillzhang 20jinshanzha...
阅读全文
posted @ 2010-05-25 14:31
KimhillZhang
阅读(1797)
推荐(0)
摘要:
protected void Page_Load(object sender, EventArgs e) { IList<string> AList = new List<string>(); AList.Add("KimhillZhangA"); AList.Add("KimhillZhangB"); AList.Add("KimhillZhangC"); IList&l...
阅读全文
posted @ 2010-05-24 15:16
KimhillZhang
阅读(593)
推荐(1)
摘要:
文本编辑器,里面含一个Demo,下载:CKEditorAndCKFinder转:http://www.cnblogs.com/loogn/archive/2010/05/18/1738349.html
阅读全文
posted @ 2010-05-18 17:09
KimhillZhang
阅读(274)
推荐(1)
摘要:
从网上看的:第一种:select * from (Select row_number() over(order by NewsID asc) AS rownum, NewsID, NewsTitle,NewsText From T_NewsTBL) as a where rownum >= 1 and rownum <= 5第二种:select T_NewsTBL.NewsID, T_...
阅读全文
posted @ 2010-05-17 17:03
KimhillZhang
阅读(309)
推荐(0)