# SectionFormat.Columns Property

> Gets or sets the number of columns on a page.

- **Product:** TX Text Control .NET for Windows Forms
- **Section:** Reference
- **Kind:** Property
- **Introduced:** 15.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 > SectionFormat.Columns Property
- **419 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/columns-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/columns-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/columns-property/llms-full.txt

---

### Description

Gets or sets the number of columns on a page.

### Syntax

```csharp
public int Columns { get; set; }
```

```vbnet
Public Property Columns As Integer
```

### Examples

The following example configures the layout of the first document section by using `SectionFormat.Columns`.

```csharp
SectionFormat sectionFormat = textControl.Sections[1].Format;

sectionFormat.Columns = 1;
Console.WriteLine($"Columns used by Section Format: {sectionFormat.Columns}");
```

```vbnet
Dim sectionFormat As SectionFormat = textControl.Sections(1).Format

sectionFormat.Columns = 1
Console.WriteLine($"Columns used by Section Format: {sectionFormat.Columns}")
```

### Remarks

The property's default value is 1.

The property returns 0 when the text selection contains multiple sections with mixed setting. The [Selection.IsCommonValueSelected](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/selection/iscommonvalueselected-method/llms-full.txt) method can be used to check for mixed attributes.

---

## Nearby

- **Previous:** [SectionFormat.ColumnLineWidth Property](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/columnlinewidth-property/llms-full.txt)
- **Next:** [SectionFormat.ColumnWidths Property](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/columnwidths-property/llms-full.txt)
