Welcome to my blog

RamondLee

2011年2月14日

使用CustomValidator验证用户输入

摘要: 在验证某些用户输入时, ASP.NET提供的那几个简单的验证控件肯能难以满足需求。 例如如果我们需要一个复杂的,有条件的验证时, 就必须自己来定义验证方法了。下面是一个简单的使用CustomValidator的例子。1[代码] 注意 “ValidateEmptyText” 属性, 如果不把这个属性设置为true的话, 那么当输入为空时就不会激发验证方法了。 在ValidateTBDays 中, var number =/^[1-9]\d{0,1}$/; 这个正则表达式是用来验证输入的值是否是1-99之间的数的。 另外在写验证函数时,还要注意eventArg 中的属性V 阅读全文

posted @ 2011-02-14 14:40 RamondLee 阅读(320) 评论(0) 推荐(0)

2010年8月21日

Static Constructor(Type Constructor)

摘要: there are two ways can make the Static Constructor be called.1. if you want to initialize a instance of this type2. if you want to access a static noninherited member of this typeplease pay attention ... 阅读全文

posted @ 2010-08-21 11:29 RamondLee 阅读(490) 评论(0) 推荐(0)

2010年8月18日

Innovation

摘要: I read an article about Schumpeter one of the most famous economists.thearticle talked about the Schumpeter ’s theroy. One of them is about the relationship between innvoationand developing of t... 阅读全文

posted @ 2010-08-18 17:47 RamondLee 阅读(311) 评论(0) 推荐(0)
HttpContext.Current.Server.Execute()

摘要: you can get the final html content of aspx without sending a request to this page. 阅读全文

posted @ 2010-08-18 17:34 RamondLee 阅读(623) 评论(0) 推荐(0)
asp.net 页面生命周期

摘要: 阅读全文

posted @ 2010-08-18 17:28 RamondLee 阅读(109) 评论(0) 推荐(0)

2010年8月4日

what is Serialization

摘要: Serialization is nothing but the process of converting the state of an object into a format that can be either persisted to disk or transmitted.The .Net framework features two options for serializing ... 阅读全文

posted @ 2010-08-04 20:44 RamondLee 阅读(144) 评论(0) 推荐(0)

2009年9月28日

关于C#中的虚方法的问题

摘要: 一直以来都对面向对象的语言如何实现虚方法和重写的这些问题很感兴趣,虽然知道最基本的一些如何使用这种设计方式,但是却一直没有找到一个详细的资料告诉我C#到底是如何做到的。最近没什么事情就把一直想看的<<essential .net>>这本书翻了一下,让我对这件事有了一定程度了解(至少我认为是这样)。 因为这个问题会涉及到方法表,所以我认为应该先把对象如何在内存中存储的来做一... 阅读全文

posted @ 2009-09-28 17:37 RamondLee 阅读(824) 评论(0) 推荐(0)