# SectionFormat Constructor

> Creates a new instance of the SectionFormat class.

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

---

### Description

Creates a new instance of the [SectionFormat](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/llms-full.txt) class.

### Syntax

#### SectionFormat()

Creates an empty [SectionFormat](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/llms-full.txt) object. Further properties must be set.

```csharp
public SectionFormat();
```

```vbnet
Public Sub New()
```

#### SectionFormat(int, int)

Creates a [SectionFormat](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/llms-full.txt) object for a section with equal column widths. The [SectionFormat.EqualColumnWidth](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/equalcolumnwidth-property/llms-full.txt) property is automatically set to true.

```csharp
public SectionFormat(int columns, int columnDistance);
```

```vbnet
Public Sub New(columns As Integer, columnDistance As Integer)
```

| Parameter | Description |
|---|---|
| columns | Specifies the number of columns for the section. |
| columnDistance | Specifies the distance between equal columns. |

#### SectionFormat(int, int\[\], int\[\])

Creates a [SectionFormat](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/llms-full.txt) object for a section with individual column widths and distances. The [SectionFormat.EqualColumnWidth](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/sectionformat/equalcolumnwidth-property/llms-full.txt) property is automatically set to false.

```csharp
public SectionFormat(int columns, int[] columnWidths, int[] columnDistances);
```

```vbnet
Public Sub New(columns As Integer, columnWidths As Integer(), columnDistances As Integer())
```

| Parameter | Description |
|---|---|
| columns | Specifies the number of columns for the section. |
| columnWidths | Specifies the widths of the columns. The array must contain exactly an element for each column. |
| columnDistances | Specifies the distances between the columns. The array must contain exactly an element for each distance. The size of this array must be one less the size of the columnWidths array. The sum of all widths and distances must not exceed the width of the page's text area. Otherwise an exception occurs. The width of the text area is the page width less the left and the right page margin. |

### Examples

The following example creates a Section Format instance and configures its break kind setting for a document workflow.

```csharp
SectionFormat sectionFormat = new();
sectionFormat.BreakKind = SectionBreakKind.BeginAtNewLine;
```

```vbnet
Dim sectionFormat As New SectionFormat()
sectionFormat.BreakKind = SectionBreakKind.BeginAtNewLine
```

---

## Nearby

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