# DocumentLink.AutoGenerationType Property

> Gets the type of auto-generation. A document link in a table of contents is automatically generated when the table of contents is inserted into the document.

- **Product:** TX Text Control .NET for WPF
- **Section:** Reference
- **Kind:** Property
- **Introduced:** 29.0
- **Namespace:** `TXTextControl`
- **Package:** `TXTextControl.TextControl.WPF.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 for WPF > Reference > TXTextControl > DocumentLink.AutoGenerationType Property
- **589 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/documentlink/autogenerationtype-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/documentlink/autogenerationtype-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/documentlink/autogenerationtype-property/llms-full.txt

---

### Description

Gets the type of auto-generation. A document link in a table of contents is automatically generated when the table of contents is inserted into the document.

### Syntax

```csharp
public AutoGenerationType AutoGenerationType { get; }
```

```vbnet
Public ReadOnly Property AutoGenerationType As AutoGenerationType
```

### Members

| Value | Description |
|---|---|
| None | The document link is not automatically generated. |
| TableOfContents | The document link has automatically been generated for an entry in a table of contents. |

### Examples

The following example creates an internal link to the customer-details destination by using `DocumentLink.AutoGenerationType`.

```csharp
DocumentTarget target = new("CustomerDetails");
textControl.DocumentTargets.Add(target);
DocumentLink documentLink = new("View customer details", target);
textControl.DocumentLinks.Add(documentLink);

Console.WriteLine($"Auto Generation Type: {documentLink.AutoGenerationType}");
Console.WriteLine("Document Link is ready for use.");
```

```vbnet
Dim target As New DocumentTarget("CustomerDetails")
textControl.DocumentTargets.Add(target)
Dim documentLink As New DocumentLink("View customer details", target)
textControl.DocumentLinks.Add(documentLink)

Console.WriteLine($"Auto Generation Type: {documentLink.AutoGenerationType}")
Console.WriteLine("Document Link is ready for use.")
```

### Limitations

Read only.

---

## Nearby

- **Previous:** [DocumentLink Class](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/documentlink/llms-full.txt)
- **Next:** [DocumentLink Constructor](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/documentlink/constructor/llms-full.txt)
