# TextControl.FormFieldSelectionChanged Event

> Occurs when the selected item of a SelectionFormField has been changed. The event handler receives an argument of type SelectionFormFieldEventArgs containing data related to this event. The event does not occur, when the SelectionFormField.SelectedIndex property has been used to change the item.

- **Product:** TX Text Control .NET for WPF
- **Section:** Reference
- **Kind:** Event
- **Introduced:** 28.0
- **Namespace:** `TXTextControl.WPF`
- **Package:** `TXTextControl.TextControl.WPF.SDK` (assembly `TXTextControl.WPF.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXTextControl.WPF.dll` from the setup
- **Path:** TX Text Control .NET for WPF > Reference > TXTextControl.WPF > TextControl.FormFieldSelectionChanged Event
- **399 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf/textcontrol/formfieldselectionchanged-event/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf/textcontrol/formfieldselectionchanged-event/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf/textcontrol/formfieldselectionchanged-event/llms-full.txt

---

### Description

Occurs when the selected item of a [SelectionFormField](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/selectionformfield/llms-full.txt) has been changed. The event handler receives an argument of type [SelectionFormFieldEventArgs](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/selectionformfieldeventargs/llms-full.txt) containing data related to this event. The event does not occur, when the [SelectionFormField.SelectedIndex](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/selectionformfield/selectedindex-property/llms-full.txt) property has been used to change the item.

### Syntax

```csharp
public event SelectionFormFieldEventHandler FormFieldSelectionChanged;
```

```vbnet
Public Event FormFieldSelectionChanged As SelectionFormFieldEventHandler
```

### Examples

The following example records useful context when form field selection changed occurs.

```csharp
textControl.FormFieldSelectionChanged += (sender, e) =>
{
    Console.WriteLine($"Form Field Selection Changed at {DateTime.Now:u}");
};
```

```vbnet
AddHandler textControl.FormFieldSelectionChanged,
    Sub(sender, e)
        Console.WriteLine($"Form Field Selection Changed at {DateTime.Now:u}")
    End Sub
```

---

## Nearby

- **Previous:** [TextControl.FormFields Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf/textcontrol/formfields-property/llms-full.txt)
- **Next:** [TextControl.FormFieldSettingsChanged Event](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol-wpf/textcontrol/formfieldsettingschanged-event/llms-full.txt)
