# TextControl.PrintPreview Method

> Shows a print preview of the current document.

- **Product:** TX Text Control .NET for Windows Forms
- **Section:** Reference
- **Kind:** Method
- **Namespace:** `TXTextControl`
- **Package:** `TXTextControl.TextControl.WinForms.SDK` (assembly `TXTextControl.Windows.Forms.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXTextControl.Windows.Forms.dll` from the setup
- **Path:** TX Text Control .NET for Windows Forms > Reference > TXTextControl > TextControl.PrintPreview Method
- **519 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/textcontrol/printpreview-method/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/textcontrol/printpreview-method/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/textcontrol/printpreview-method/llms-full.txt

---

### Description

Shows a print preview of the current document.

### Syntax

#### PrintPreview(string)

Shows a print preview of the current document.

```csharp
public void PrintPreview(string docName);
```

```vbnet
Public Sub PrintPreview(docName As String)
```

| Parameter | Description |
|---|---|
| docName | Specifies the document's name. |

#### PrintPreview(PrintDocument)

Shows a print preview of the current document using settings from the specified PrintDocument object.

```csharp
public void PrintPreview(PrintDocument printDocument);
```

```vbnet
Public Sub PrintPreview(printDocument As PrintDocument)
```

| Parameter | Description |
|---|---|
| printDocument | Specifies an instance of the PrintDocument class. |

### Examples

The following example opens a print preview for the current document. The created object is then available to the surrounding document workflow.

```csharp
textControl.PrintPreview("CustomerName");
Console.WriteLine("Text Control is ready for use.");
```

```vbnet
textControl.PrintPreview("CustomerName")
Console.WriteLine("Text Control is ready for use.")
```

---

## Nearby

- **Previous:** [TextControl.Print Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/textcontrol/print-method/llms-full.txt)
- **Next:** [TextControl.Redo Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/textcontrol/redo-method/llms-full.txt)
