# DataForm DataFormComboBoxField SelectedItem Becomes Null After Commit Button Click

## Environment

<table>
	<tbody>
		<tr>
			<th scope="row">Product Version</th>
			<td></td>
		</tr>
		<tr>
			<th scope="row">Product</th>
			<td>RadDataForm for WPF</td>
		</tr>
	</tbody>
</table>

## Description

The following setup produces a `null` value in the `SelectedItem` of the RadDataFormComboBoxField on Commit button click.

```XAML
	<telerik:DataFormComboBoxField DataMemberBinding="{Binding SelectedItem}"
								   ItemsSource="{Binding Items}" />
```

This happens if the Commit button unloads the control from the visual tree. For example, if hosted in dialog window that gets closed on commit.

## Solution

To resolve this, add a `RadComboBox` control directly inside of the `Content` of the data field.

```XAML
	<telerik:DataFormComboBoxField>
		<telerik:RadComboBox SelectedItem="{Binding SelectedItem}" 
							 ItemsSource="{Binding Items}"  />
	</telerik:DataFormComboBoxField>  
```
