From Dino's book.

When DataType refers to a value of a non-String type such as DateTime, validation is included. When DataType refers to a special meaning of a String type, no validation is taken into account; in this regard, the DataType attribute works as a plain display attribute. For example, using DataType[DataType. EmailAddress] ensures that any content is rendered as a hyperlink, but not that the content is checked against the typical e-mail address format. If you want validation, you have to add a regular expression

posted on 2010-07-19 14:51  武汉虫虫  阅读(166)  评论(0编辑  收藏  举报

导航