# pane.Pane.findWindow

- **Module:** pane
- **Package:** libtmux
- **Language:** TypeScript
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-ts/blob/073b9d7dedad900bff6f5ec0ea47794e40225870/packages/libtmux/src/pane.ts#L716
- **Page:** https://libtmux.org/en/ts/latest/reference/pane-pane-findwindow/

```
findWindow(pattern: string): Promise<void>
```

Search windows interactively from this pane.

The promise resolves once the mode is on screen, not once someone has
chosen: tmux answers this command as soon as it opens the mode. Bind a
tmux command to the selection to act on what was picked.

tmux needs a client attached to the session to draw this. With none, it
does nothing and reports success, so a headless run is told it worked.

## Examples

```ts
await pane.findWindow("editor");
```

## Parameters

- `pattern` (`string`)

## tmux command

The tmux commands behind `findWindow`.

- [`find-window`](/en/tmux/latest/manual/find-window/)

## tmux C API

The C declarations in tmux that implement these commands.

- [`cmd_find_window_entry`](/en/tmux/latest/reference/c-variable-cmd_find_window_entry/) (attribute)
- [`cmd_find_window_exec`](/en/tmux/latest/reference/c-function-cmd-find-window-c-cmd_find_window_exec/) (function)

## In other ports

Search windows interactively from a pane

| Language | Equivalent |
| --- | --- |
| Python | [`libtmux.Pane.find_window`](/en/py/latest/reference/libtmux-pane-find_window/) (method) |
| Rust | no equivalent on `Pane` |
| Go | [`tmux.Pane.FindWindow`](/en/go/latest/reference/tmux-pane-findwindow/) (method) |
| Java | no equivalent on `Pane` |
| C# | [`LibTmux.Pane.FindWindowAsync`](/en/csharp/latest/reference/libtmux-pane-findwindowasync/) (method) |
| C++ | no equivalent on `Pane` |
| Swift | no equivalent on `Pane` |

No equivalent is recorded in Ruby, Lua, PowerShell, Julia, Elixir, Kotlin, Scala or F#.
