# XmlElement.AutoSelect Property

> Determines whether the text of a newly added XML element is automatically selected.

- **Product:** TX Text Control .NET Server
- **Section:** Reference
- **Kind:** Property
- **Namespace:** `TXTextControl`
- **Package:** `TXTextControl.TextControl.Core.SDK` (assembly `TXTextControl.Core.dll`, from the private NuGet feed or Text Control Offline Packages)
- **Package:** `TXTextControl.TextControl.ASP.SDK` (assembly `TXTextControl.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXTextControl.dll` from the setup
- **Path:** TX Text Control .NET Server > Reference > TXTextControl > XmlElement.AutoSelect Property
- **355 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/xmlelement/autoselect-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/xmlelement/autoselect-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/xmlelement/autoselect-property/llms-full.txt

---

### Description

Determines whether the text of a newly added XML element is automatically selected.

### Syntax

```csharp
public bool AutoSelect { get; set; }
```

```vbnet
Public Property AutoSelect As Boolean
```

### Examples

The following example uses `XmlElement.AutoSelect` to configure auto select as part of the xml element workflow. The configured value is checked before the workflow continues.

```csharp
xmlElement.AutoSelect = true;
if (xmlElement.AutoSelect)
{
    Console.WriteLine("Xml Element: Auto Select is enabled.");
}
```

```vbnet
xmlElement.AutoSelect = True
If xmlElement.AutoSelect Then
    Console.WriteLine("Xml Element: Auto Select is enabled.")
End If
```

---

## Nearby

- **Previous:** [XmlElement.AddChild Method](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/xmlelement/addchild-method/llms-full.txt)
- **Next:** [XmlElement.AutoText Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol/xmlelement/autotext-property/llms-full.txt)
