HtmlHelperLabelExtensions.LabelForModel HtmlHelperLabelExtensions.LabelForModel HtmlHelperLabelExtensions.LabelForModel HtmlHelperLabelExtensions.LabelForModel Method

Definition

Overloads

LabelForModel(IHtmlHelper) LabelForModel(IHtmlHelper) LabelForModel(IHtmlHelper) LabelForModel(IHtmlHelper)

Returns a <label> element for the current model.

LabelForModel(IHtmlHelper, Object) LabelForModel(IHtmlHelper, Object) LabelForModel(IHtmlHelper, Object) LabelForModel(IHtmlHelper, Object)

Returns a <label> element for the current model.

LabelForModel(IHtmlHelper, String) LabelForModel(IHtmlHelper, String) LabelForModel(IHtmlHelper, String) LabelForModel(IHtmlHelper, String)

Returns a <label> element for the current model.

LabelForModel(IHtmlHelper, String, Object) LabelForModel(IHtmlHelper, String, Object) LabelForModel(IHtmlHelper, String, Object) LabelForModel(IHtmlHelper, String, Object)

Returns a <label> element for the current model.

LabelForModel(IHtmlHelper) LabelForModel(IHtmlHelper) LabelForModel(IHtmlHelper) LabelForModel(IHtmlHelper)

Returns a <label> element for the current model.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Html::IHtmlContent ^ LabelForModel(Microsoft::AspNetCore::Mvc::Rendering::IHtmlHelper ^ htmlHelper);
public static Microsoft.AspNetCore.Html.IHtmlContent LabelForModel (this Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper htmlHelper);
static member LabelForModel : Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper -> Microsoft.AspNetCore.Html.IHtmlContent
<Extension()>
Public Function LabelForModel (htmlHelper As IHtmlHelper) As IHtmlContent

Parameters

htmlHelper
IHtmlHelper IHtmlHelper IHtmlHelper IHtmlHelper

The IHtmlHelper instance this method extends.

Returns

A new IHtmlContent containing the <label> element.

LabelForModel(IHtmlHelper, Object) LabelForModel(IHtmlHelper, Object) LabelForModel(IHtmlHelper, Object) LabelForModel(IHtmlHelper, Object)

Returns a <label> element for the current model.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Html::IHtmlContent ^ LabelForModel(Microsoft::AspNetCore::Mvc::Rendering::IHtmlHelper ^ htmlHelper, System::Object ^ htmlAttributes);
public static Microsoft.AspNetCore.Html.IHtmlContent LabelForModel (this Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper htmlHelper, object htmlAttributes);
static member LabelForModel : Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper * obj -> Microsoft.AspNetCore.Html.IHtmlContent
<Extension()>
Public Function LabelForModel (htmlHelper As IHtmlHelper, htmlAttributes As Object) As IHtmlContent

Parameters

htmlHelper
IHtmlHelper IHtmlHelper IHtmlHelper IHtmlHelper

The IHtmlHelper instance this method extends.

htmlAttributes
Object Object Object Object

An Object that contains the HTML attributes for the element. Alternatively, an IDictionary<TKey,TValue> instance containing the HTML attributes.

Returns

A new IHtmlContent containing the <label> element.

LabelForModel(IHtmlHelper, String) LabelForModel(IHtmlHelper, String) LabelForModel(IHtmlHelper, String) LabelForModel(IHtmlHelper, String)

Returns a <label> element for the current model.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Html::IHtmlContent ^ LabelForModel(Microsoft::AspNetCore::Mvc::Rendering::IHtmlHelper ^ htmlHelper, System::String ^ labelText);
public static Microsoft.AspNetCore.Html.IHtmlContent LabelForModel (this Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper htmlHelper, string labelText);
static member LabelForModel : Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper * string -> Microsoft.AspNetCore.Html.IHtmlContent
<Extension()>
Public Function LabelForModel (htmlHelper As IHtmlHelper, labelText As String) As IHtmlContent

Parameters

htmlHelper
IHtmlHelper IHtmlHelper IHtmlHelper IHtmlHelper

The IHtmlHelper instance this method extends.

labelText
String String String String

The inner text of the element.

Returns

A new IHtmlContent containing the <label> element.

LabelForModel(IHtmlHelper, String, Object) LabelForModel(IHtmlHelper, String, Object) LabelForModel(IHtmlHelper, String, Object) LabelForModel(IHtmlHelper, String, Object)

Returns a <label> element for the current model.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Html::IHtmlContent ^ LabelForModel(Microsoft::AspNetCore::Mvc::Rendering::IHtmlHelper ^ htmlHelper, System::String ^ labelText, System::Object ^ htmlAttributes);
public static Microsoft.AspNetCore.Html.IHtmlContent LabelForModel (this Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper htmlHelper, string labelText, object htmlAttributes);
static member LabelForModel : Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper * string * obj -> Microsoft.AspNetCore.Html.IHtmlContent
<Extension()>
Public Function LabelForModel (htmlHelper As IHtmlHelper, labelText As String, htmlAttributes As Object) As IHtmlContent

Parameters

htmlHelper
IHtmlHelper IHtmlHelper IHtmlHelper IHtmlHelper

The IHtmlHelper instance this method extends.

labelText
String String String String

The inner text of the element.

htmlAttributes
Object Object Object Object

An Object that contains the HTML attributes for the element. Alternatively, an IDictionary<TKey,TValue> instance containing the HTML attributes.

Returns

A new IHtmlContent containing the <label> element.

Applies to