# ex command

The ex command exits the current item
without saving changes. Control returns to TCL, or to the next item
in the list if more than one item was requested.

If the item has changed since the Editor was invoked and
the ex command is issued, the message item changed, exit it (y/n=cr) ? displays. Pressing y exits the item without saving changes. To save the item, see [fi command](https://d3codex.com/editor/fi-command/) or [fs command](https://d3codex.com/editor/fs-command/).

## Syntax

```
 ex
```

## Example(s)

```

ed bp *
first.program
top
.ex
’first.program’ exited.
second.program
top
.ex
’second.program’ exited.
```

## See also

- [Error messages](https://d3codex.com/editor/error-messages/)
- [ex command](https://d3codex.com/editor/ex-command/)
- [exk command](https://d3codex.com/editor/exk-command/)
- [fd command](https://d3codex.com/editor/fd-command/)
- [fi command](https://d3codex.com/editor/fi-command/)
- [fs command](https://d3codex.com/editor/fs-command/)
- [fso command](https://d3codex.com/editor/fso-command/)
- [me command](https://d3codex.com/editor/me-command/)
- [Editor overview](https://d3codex.com/editor/editor-overview/)
- [ex command](https://d3codex.com/editor/ex-command/)
- [xf command](https://d3codex.com/editor/xf-command/)

---
Source: https://d3codex.com/editor/ex-command/ - part of the D3Codex reference.
