HtmlHelper.ObjectToDictionary(Object) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a dictionary from an object, by adding each public instance property as a key with its associated value to the dictionary. It will expose public properties from derived types as well. This is typically used with objects of an anonymous type.
public static System.Collections.Generic.IDictionary<string,object> ObjectToDictionary (object value);
static member ObjectToDictionary : obj -> System.Collections.Generic.IDictionary<string, obj>
Public Shared Function ObjectToDictionary (value As Object) As IDictionary(Of String, Object)
Parameters
- value
- Object
The object to be converted.
Returns
The created dictionary of property names and property values.