|
|
submitted by
Lord
3 months, 30 days ago
blog.codeville.net — MVC Preview 5 comes with two new API pieces that seem relevant to validation:
ModelState. Controllers now have an official way to pass validation error information to views. Populate ViewData.ModelState, then you can use the built-in HTML helpers to render error message summaries, and to highlight input fields that correspond to errors.
Model binders. Controllers are expected to populate model objects from form posts using the IModelBinder API. You can create custom binders - the framework calls your binder to obtain a value for each model property. (If you don’t understand this, don’t worry - it turns out not to be relevant.)
|
|
tags:
ASP.NET | tag it
Everyones tags: | Your tags: | |
|
|
|
Add a live kick counter to your blog >>
You can even customize the image by choosing your own colors, and then clicking
the button below to update the preview and the html code:
Simply copy and paste this HTML into your blog post.
Users who kicked this story:
No comments so far
|