In This Article

NewRowTemplateBehavior Class

Provides attached behavior for DataGrid controls to customize the new row template.

public static class NewRowTemplateBehavior
Inheritance:
object object

Methods

GetDefaultTemplate(DataGrid)

Gets the value of the DefaultTemplateProperty attached property for a specified DataGrid.

public static ControlTemplate? GetDefaultTemplate(DataGrid obj)
Parameter Type Description
obj DataGrid

The object to which the attached property is retrieved.

Returns

ControlTemplate

GetTemplate(DataGrid)

Gets the value of the TemplateProperty attached property for a specified DataGrid.

public static ControlTemplate? GetTemplate(DataGrid obj)
Parameter Type Description
obj DataGrid

The object to which the attached property is retrieved.

Returns

ControlTemplate

SetTemplate(DataGrid, ControlTemplate?)

Sets the value of the TemplateProperty attached property to a specified DataGrid.

public static void SetTemplate(DataGrid obj, ControlTemplate? value)
Parameter Type Description
obj DataGrid

The object to which the attached property is written.

value ControlTemplate

A value indicating the ControlTemplate to use for the "new" row in a DataGrid.

Fields

DefaultTemplateProperty

Defines the DefaultTemplate attached property.

public static readonly DependencyProperty DefaultTemplateProperty

TemplateProperty

Defines the Template attached property.

public static readonly DependencyProperty TemplateProperty

Inherited Members