# LibTmux.Session.SelectWindowAsync

- **Module:** LibTmux
- **Package:** LibTmux
- **Language:** C#
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-dotnet/blob/cf34b255c896d19a97e7d7fabea58609c916012d/src/LibTmux/Session.Lifecycle.cs#L144
- **Page:** https://libtmux.org/en/csharp/latest/reference/libtmux-session-selectwindowasync/

```
LibTmux.Session.SelectWindowAsync(target: string, cancellationToken: CancellationToken) -> Task<Window>
```

Selects a window in this session.

## Parameters

- `target` (`string`): The window target.
- `cancellationToken` (`CancellationToken`): Cancels the tmux command.

## Returns

The window that is active afterwards.
