# LibTmux.Pane.CaptureToBufferAsync

- **Module:** LibTmux
- **Package:** LibTmux
- **Language:** C#
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-dotnet/blob/cf34b255c896d19a97e7d7fabea58609c916012d/src/LibTmux/Pane.Capture.cs#L87
- **Page:** https://libtmux.org/en/csharp/latest/reference/libtmux-pane-capturetobufferasync/

```
LibTmux.Pane.CaptureToBufferAsync(bufferName: string, request: CapturePaneRequest?, cancellationToken: CancellationToken) -> Task
```

Captures the pane's contents into a tmux buffer.

## Parameters

- `bufferName` (`string`): The buffer to write.
- `request` (`CapturePaneRequest?`): What to capture.
- `cancellationToken` (`CancellationToken`): Cancels the tmux command.
