ObjectInfo.Print(Object, Int32, Int32) 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.
Renders the property names and values of the specified object and of any subobjects.
public static System.Web.WebPages.HelperResult Print(object value, int depth = 10, int enumerationLength = 1000);
static member Print : obj * int * int -> System.Web.WebPages.HelperResult
Public Shared Function Print (value As Object, Optional depth As Integer = 10, Optional enumerationLength As Integer = 1000) As HelperResult
Parameters
- value
- Object
The object to render information for.
- depth
- Int32
Optional. Specifies the depth of nested subobjects to render information for. The default is 10.
- enumerationLength
- Int32
Optional. Specifies the maximum number of characters that the method displays for object values. The default is 1000.
Returns
For a simple variable, returns the type and the value. For an object that contains multiple items, returns the property name or key and the value for each property.
Exceptions
enumerationLength
is less than or equal to zero.