# Customizing DataForm Elements

The `RadDataForm` control in Progress® Telerik® UI for WPF supports styles for the form and its elements. This article covers styles for the form, its collection navigator, and its data fields.

## Style the RadDataForm

Create an implicit style targeting `RadDataForm` to style the form. Alternatively, give the style an `x:Key` and assign it to the control's `Style` property.

The following example defines an implicit style for `RadDataForm`:

```XAML
<Window.Resources>
    
    
    <Style TargetType="telerik:RadDataForm">
        <Setter Property="Background" Value="Pink" />
        <Setter Property="BorderBrush" Value="Yellow" />
        <Setter Property="BorderThickness" Value="3" />
    </Style>
</Window.Resources>
<Grid>
    <telerik:RadDataForm AutoGenerateFields="True" />
</Grid>
```

> caption RadDataForm with a custom style in the Office2016 theme

![RadDataForm with a custom style in the Office2016 theme](https://www.telerik.com/products/wpf/documentation/assets/a13d79ff2c9fc153afb51106a4783f7d/raddataform_style.png)

## Style the CollectionNavigator

The `CollectionNavigator` hosts the buttons for navigating, adding, editing, and deleting items. To style it, create an implicit style targeting `CollectionNavigator`.

The following example defines an implicit style for `CollectionNavigator`:

```XAML
<Window.Resources>
    
    
    <Style xmlns:dataForm="clr-namespace:Telerik.Windows.Controls.Data.DataForm;assembly=Telerik.Windows.Controls.Data"
                  TargetType="dataForm:CollectionNavigator">
        <Setter Property="Background" Value="Red" />
        <Setter Property="BorderBrush" Value="Green" />
        <Setter Property="BorderThickness" Value="3" />
    </Style>
</Window.Resources>
<Grid>
    <telerik:RadDataForm AutoGenerateFields="True" />
</Grid>
```

> caption CollectionNavigator with a custom style in the Office2016 theme

![CollectionNavigator with a custom style in the Office2016 theme](https://www.telerik.com/products/wpf/documentation/assets/9edb24823c658aa202667c9ad15e6823/raddataform_collectionnavigator_style.png)

## Style the Data Fields

`DataFormDataField` is the base class for the form's fields. Other field types include `DataFormComboBoxField`, `DataFormCheckBoxField`, and `DataFormDateField`.

To style the fields, create a style targeting `DataFormDataField` and assign it to the `RadDataForm` control's `DataFieldStyle` property. The following example defines the style:

```XAML
<Window.Resources>
    
    

    <Style x:Key="DataFormDataFieldStyle" TargetType="telerik:DataFormDataField">
        <Setter Property="Background" Value="Red" />
    </Style>
</Window.Resources>
<Grid>
    <telerik:RadDataForm AutoGenerateFields="True" DataFieldStyle="{StaticResource DataFormDataFieldStyle}" />
</Grid>
```

> caption RadDataForm with a custom DataFieldStyle in the Office2016 theme

![RadDataForm with a custom DataFieldStyle in the Office2016 theme](https://www.telerik.com/products/wpf/documentation/assets/158c614c7a127857cc1524e441c1d837/raddataform_datafieldstyle.png)

## See Also

* [Setting a Theme Using Implicit Styles](https://www.telerik.com/products/wpf/documentation/styling-and-appearance/styling-apperance-setting-a-theme-overview)
* [Editing Control Templates](https://www.telerik.com/products/wpf/documentation/styling-and-appearance/styling-apperance-editing-control-templates)
* [Autogenerated Fields](https://www.telerik.com/products/wpf/documentation/controls/raddataform/getting-started/autogenerated-fields)
