Skip to main content

ButtonGroupBuilder.ButtonTemplate(TemplateName) Method

Specifies the client-side buttonTemplate.

Namespace: DevExtreme.AspNet.Mvc.Builders

Assembly: DevExtreme.AspNet.Core.dll

Declaration

public ButtonGroupBuilder ButtonTemplate(
    TemplateName name
)

Parameters

Name Type Description
name TemplateName

A template name.

Returns

Type Description
ButtonGroupBuilder

A reference to this instance after the method is called.

Remarks

This method applies an external template to a button. Refer to External Templates for more information and code examples.

@(Html.DevExtreme().ButtonGroup()
    .ButtonTemplate(new TemplateName("myButtonGroup_buttonTemplate"))
)

@using(Html.DevExtreme().NamedTemplate("myButtonGroup_buttonTemplate")) {
    <div>
        Template content
    </div>
}
See Also