# GridToolBarCustomCommandBuilder

## Methods

### Name(System.String)

Sets the command name.

#### Parameters

##### name - `System.String`

The name of the command

#### RETURNS

Returns the current [GridToolBarCustomCommandBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/gridtoolbarcustomcommandbuilder) instance for method chaining.

#### Example

```
 
                @(Html.Kendo().Grid<User>()
                       .Name("grid")
                       .ToolBar(toolbar =>
                       {
                          toolbar.Custom().Name("CustomCommand");
                       })
                )
             
```

### ClientTemplateView(Microsoft.AspNetCore.Html.IHtmlContent)

Sets the toolbar command template handler.

#### Parameters

##### value - `Microsoft.AspNetCore.Html.IHtmlContent`

The partial view that will be rendered for the toolbar command template.

#### RETURNS

Returns the current [GridToolBarCustomCommandBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/gridtoolbarcustomcommandbuilder) instance for method chaining.

#### Example

```
 
                @(Html.Kendo().Grid<User>()
                       .Name("grid")
                       .ToolBar(toolbar =>
                       {
                          toolbar.Custom().Name("CustomCommand").ClientTemplateView(Html.Partial("_CustomCommand"));
                       })
                )
             
```

### ClientTemplateHandler(System.String)

Sets the toolbar command template handler.

#### Parameters

##### handler - `System.String`

#### RETURNS

Returns the current [GridToolBarCustomCommandBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/gridtoolbarcustomcommandbuilder) instance for method chaining.

#### Example

```
 
                @(Html.Kendo().Grid<User>()
                       .Name("grid")
                       .ToolBar(toolbar =>
                       {
                          toolbar.Custom().Name("CustomCommand").ClientTemplateHandler("myHandler");
                       })
                )
             
```

### ClientTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Sets the toolbar command template.

#### Parameters

##### template - TemplateBuilder\<TModel>

The template component that will be set for the command template.

#### RETURNS

Returns the current [GridToolBarCustomCommandBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/gridtoolbarcustomcommandbuilder) instance for method chaining.

#### Example

```
 
                @(Html.Kendo().Grid<User>()
                       .Name("grid")
                       .ToolBar(toolbar =>
                       {
                          toolbar.Custom().Name("CustomCommand").ClientTemplate(Html.Kendo()
                                                                         .Template()
                                                                         .AddHtml("Some Template")
                                                                );
                       })
                )
             
```

### ClientTemplate(System.String)

Sets the toolbar command template.

#### Parameters

##### template - `System.String`

The action defining the template.

#### RETURNS

Returns the current [GridToolBarCustomCommandBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/gridtoolbarcustomcommandbuilder) instance for method chaining.

#### Example

```
 
                @(Html.Kendo().Grid<User>()
                       .Name("grid")
                       .ToolBar(toolbar =>
                       {
                          toolbar.Custom().Name("CustomCommand").ClientTemplate("Custom Command");
                       })
                )
             
```

### ClientTemplateId(System.String)

Sets the id of the script element which contains the client-side toolbar command template.

#### Parameters

##### template - `System.String`

The ID of script that will be rendered for the toolbar command template.

#### Example

```
 
                @(Html.Kendo().Grid<User>()
                       .Name("grid")
                       .ToolBar(toolbar =>
                       {
                          toolbar.Custom().Name("CustomCommand").ClientTemplateId("customCommandTemplate");
                       })
                )
             
```

### Text(System.String)

Sets the text displayed in the button.

#### Parameters

##### text - `System.String`

The text which should be displayed

#### RETURNS

The current instance of the  builder.

### IconClass(System.String)

The class for the web font icon of the button.

#### Parameters

##### iconClass - `System.String`

The class for the web font icon of the button

#### RETURNS

The current instance of the  builder.

### HtmlAttributes(System.Object)

Sets the HTML attributes.

#### Parameters

##### attributes - `System.Object`

The HTML attributes.

#### RETURNS

The current instance of the  builder.

### HtmlAttributes(System.Collections.Generic.IDictionary)

Sets the HTML attributes.

#### Parameters

##### attributes - `System.Collections.Generic.IDictionary<String,Object>`

The HTML attributes.

#### RETURNS

The current instance of the  builder.
