# HeaderFooter.Tables Property

> Gets a collection of all tables in the header or footer. The property's value is an object of the type TableCollection.

- **Product:** TX Text Control .NET for Windows Forms
- **Section:** Reference
- **Kind:** Property
- **Introduced:** 10.1
- **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 > HeaderFooter.Tables Property
- **703 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/headerfooter/tables-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/headerfooter/tables-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/headerfooter/tables-property/llms-full.txt

---

### Description

Gets a collection of all tables in the header or footer. The property's value is an object of the type [TableCollection](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/tablecollection/llms-full.txt).

### Syntax

```csharp
public TableCollection Tables { get; }
```

```vbnet
Public ReadOnly Property Tables As TableCollection
```

### Examples

The following example adds a compact two-column metadata table to a header.

```csharp
HeaderFooterCollection headers = textControl.Sections[1].HeadersAndFooters;
headers.Add(HeaderFooterType.Header);
HeaderFooter headerFooter = headers.GetItem(HeaderFooterType.Header);
headerFooter.Tables.Add(1, 2, 10);
Table metadata = headerFooter.Tables.GetItem(10);
metadata.Cells[1, 1].Text = "Department";
metadata.Cells[1, 2].Text = "Finance";
```

```vbnet
Dim headers As HeaderFooterCollection = textControl.Sections(1).HeadersAndFooters
headers.Add(HeaderFooterType.Header)
Dim headerFooter As HeaderFooter = headers.GetItem(HeaderFooterType.Header)
headerFooter.Tables.Add(1, 2, 10)
Dim metadata As Table = headerFooter.Tables.GetItem(10)
metadata.Cells(1, 1).Text = "Department"
metadata.Cells(1, 2).Text = "Finance"
```

### Limitations

Read only.

---

## Nearby

- **Previous:** [HeaderFooter.SubTextParts Property](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/headerfooter/subtextparts-property/llms-full.txt)
- **Next:** [HeaderFooter.TablesOfContents Property](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/headerfooter/tablesofcontents-property/llms-full.txt)
