开发者

How to Determine ASP.NET MVC 1.0 Validation State inside the View

I need to customize the validation message style. The way I am approaching this is to wrap the ValidationSumma开发者_StackOverflow社区ry helper with a styled div. The problem I have is that the div is visible even when there is no error on the page. Is there a way to determine if the ModelState has an error inside the view? Or should I approach this problem some other way.

Thank You!


This doesn't work? ViewData.ModelState.IsValid

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜