New to Telerik UI for ASP.NET Core? Start a free 30-day trial

Kendo UI PropertyGridToolbar TagHelper PropertyGridToolbarTagHelper class.

Definition

Namespace:Kendo.Mvc.TagHelpers

Assembly:Kendo.Mvc.dll

Syntax:

C#
[HtmlTargetElement("property-grid-toolbar-button", ParentTag = "toolbar", TagStructure = TagStructure.NormalOrSelfClosing)]
[RestrictChildren("icon", new string[] { })]
[SuppressTagRendering]
public class PropertyGridToolbarTagHelper : TagHelperCollectionItemBase, ITagHelper, ITagHelperComponent

Inheritance: objectTagHelperTagHelperChildBaseTagHelperCollectionItemBasePropertyGridToolbarTagHelper

Implements: ITagHelperITagHelperComponent

Inherited Members TagHelperChildBase.Init(TagHelperContext)TagHelperChildBase.AddSelfToContext(TagHelperContext)TagHelperChildBase.CreateHandler(string)TagHelperChildBase.IdPrefixTagHelper.Process(TagHelperContext, TagHelperOutput)TagHelper.Orderobject.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Example:

csharp
@addTagHelper *, Kendo.Mvc

<kendo-propertygrid name="propertygrid">
    <toolbar>
        <property-grid-toolbar-button name="MyCommand" click="handler" />
    </toolbar>
</kendo-propertygrid>

<script>
    function handler(e) {
        //handler code
    }
</script>

Child Tagsicon

Constructors

Initializes a new instance of the PropertyGridToolbarTagHelper class.

C#
public PropertyGridToolbarTagHelper()

Properties

The click handler of the toolbar command. Used for custom toolbar commands.

C#
public string Click { get; set; }

Specifies the icon's name that will be rendered inside the toolbar button. When you set this option, the PropertyGrid renders an additional span element inside the toolbar button which has a name set to the option value. This approach allows you to display an icon inside your custom toolbar commands.

C#
public string Icon { get; set; }

A class name that will be rendered inside the toolbar button. When you set this option, the PropertyGrid renders an additional span element inside the toolbar button which has a class name set to the option value. This approach allows you to display an icon inside your custom toolbar commands.

C#
public string ImageClass { get; set; }

The name of the toolbar command. Can be either a built-in ("search", "sort", "group" or "details") or a custom string. The name is output in the HTML as a value of the data-command attribute of the button.

C#
public string Name { get; set; }

The text that is displayed by the command button. If not set, the PropertyGrid will use the name option as the button text instead.

C#
public string Text { get; set; }

Methods

Adds the current TagHelper instance to its parent TagHelper.

C#
protected override void AddSelfToParent(TagHelperContext context)
Parameters:contextTagHelperContext

The TagHelper context.

Overrides: TagHelperChildBase.AddSelfToParent(TagHelperContext)

C#
public override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
Parameters:contextTagHelperContextoutputTagHelperOutputReturns:

Task

Overrides: TagHelperChildBase.ProcessAsync(TagHelperContext, TagHelperOutput)

Serializes the defined settings.

C#
public Dictionary<string, object> Serialize()
Returns:

Dictionary<string, object>