HtmlHelper.GenerateIdFromName HtmlHelper.GenerateIdFromName HtmlHelper.GenerateIdFromName Method

Definition

Overloads

GenerateIdFromName(String) GenerateIdFromName(String) GenerateIdFromName(String)

Creates an HTML element ID using the specified element name.

GenerateIdFromName(String, String) GenerateIdFromName(String, String) GenerateIdFromName(String, String)

Creates an HTML element ID using the specified element name and a string that replaces dots in the name.

GenerateIdFromName(String) GenerateIdFromName(String) GenerateIdFromName(String)

Creates an HTML element ID using the specified element name.

public static string GenerateIdFromName (string name);
static member GenerateIdFromName : string -> string
Public Shared Function GenerateIdFromName (name As String) As String

Parameters

name
String String String

The name of the HTML element.

Returns

The ID of the HTML element.

Exceptions

GenerateIdFromName(String, String) GenerateIdFromName(String, String) GenerateIdFromName(String, String)

Creates an HTML element ID using the specified element name and a string that replaces dots in the name.

public static string GenerateIdFromName (string name, string idAttributeDotReplacement);
static member GenerateIdFromName : string * string -> string
Public Shared Function GenerateIdFromName (name As String, idAttributeDotReplacement As String) As String

Parameters

name
String String String

The name of the HTML element.

idAttributeDotReplacement
String String String

The string that replaces dots (.) in the name parameter.

Returns

The ID of the HTML element.

Exceptions

The name parameter or the idAttributeDotReplacement parameter is null.

Applies to