HtmlHelper.AnonymousObjectToHtmlAttributes Method

Creates a dictionary of HTML attributes from the input object, translating underscores to dashes.

Namespace:  System.Web.WebPages.Html
Assembly:  System.Web.WebPages (in System.Web.WebPages.dll)

Syntax

'Declaration
Public Shared Function AnonymousObjectToHtmlAttributes ( _
    htmlAttributes As Object _
) As RouteValueDictionary
'Usage
Dim htmlAttributes As Object 
Dim returnValue As RouteValueDictionary 

returnValue = HtmlHelper.AnonymousObjectToHtmlAttributes(htmlAttributes)
public static RouteValueDictionary AnonymousObjectToHtmlAttributes(
    Object htmlAttributes
)
public:
static RouteValueDictionary^ AnonymousObjectToHtmlAttributes(
    Object^ htmlAttributes
)
static member AnonymousObjectToHtmlAttributes : 
        htmlAttributes:Object -> RouteValueDictionary
public static function AnonymousObjectToHtmlAttributes(
    htmlAttributes : Object
) : RouteValueDictionary

Parameters

  • htmlAttributes
    Type: System.Object
    Anonymous object describing HTML attributes.

Return Value

Type: System.Web.Routing.RouteValueDictionary
A dictionary that represents HTML attributes.

See Also

Reference

HtmlHelper Class

System.Web.WebPages.Html Namespace