# TableOfContents.MaximumStructureLevel Property

> Gets or sets the maximum structure level for this table of contents. The table of contents contains all paragraphs with a structure level less than or equal this value. It must be between 1 and 10.

- **Product:** TX Text Control .NET for Windows Forms
- **Section:** Reference
- **Kind:** Property
- **Introduced:** 29.0
- **Namespace:** `TXTextControl`
- **Package:** `TXTextControl.TextControl.WinForms.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 Windows Forms > Reference > TXTextControl > TableOfContents.MaximumStructureLevel Property
- **503 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/tableofcontents/maximumstructurelevel-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/tableofcontents/maximumstructurelevel-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/tableofcontents/maximumstructurelevel-property/llms-full.txt

---

### Description

Gets or sets the maximum structure level for this table of contents. The table of contents contains all paragraphs with a structure level less than or equal this value. It must be between 1 and 10.

### Syntax

```csharp
public short MaximumStructureLevel { get; set; }
```

```vbnet
Public Property MaximumStructureLevel As Short
```

### Examples

The following example creates a table of contents for the document's heading styles by using `TableOfContents.MaximumStructureLevel`.

```csharp
TableOfContents tableOfContents = new(1, 3) { Name = "Contents", ID = 10 };
textControl.TablesOfContents.Add(tableOfContents);

tableOfContents.MaximumStructureLevel = 10;
Console.WriteLine($"Maximum Structure Level used by Table Of Contents: {tableOfContents.MaximumStructureLevel}");
```

```vbnet
Dim tableOfContents As New TableOfContents(1, 3) With { .Name = "Contents", .ID = 10 }
textControl.TablesOfContents.Add(tableOfContents)

tableOfContents.MaximumStructureLevel = 10
Console.WriteLine($"Maximum Structure Level used by Table Of Contents: {tableOfContents.MaximumStructureLevel}")
```

---

## Nearby

- **Previous:** [TableOfContents.Length Property](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/tableofcontents/length-property/llms-full.txt)
- **Next:** [TableOfContents.MinimumStructureLevel Property](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/tableofcontents/minimumstructurelevel-property/llms-full.txt)
