Search
Render Model of a strongly typed View or ViewData dictionary of an untyped View

The project moved to http://mvccontrib.codeplex.com. I will close this project once I updated the documentation there.

Setup
  1. Drop ModelVisualizerExtension.cs somewhere in your project
  2. Include jquery in header of page
  3. Usage in View: <%= Html.ModelVisualizerExtension()%>

Usage - Limitations
Its tested with Viewmodels, that contain:
  • Generic List
  • Types of your own Namespace
  • IEnumerable<SelectListItem> (dropdownbox)
  • simple types (int, string...)
  • Enum

Example

public class ProductViewModel
{
public IEnumerable<SelectListItem> CategoryList { get; set; }
public string CategoryKey { get; set; }
public ProductInfo ProductDetail { get; set; }
public List<ProductInfo> ProductList { get; set; }

}

Default View of the page
category1.jpg

User expanded the Model display
category2.jpg

User drilled into a SelectList and a generic List
category3.jpg
Last edited Sep 4 2009 at 8:59 PM by happyspider, version 14
Updating...
© 2006-2012 Microsoft | Get Help | Privacy Statement | Terms of Use | Code of Conduct | Advertise With Us | Version 2012.1.11.18365