# Enum.CompletionAcceptanceBehavior

Roblox Engine API enum from Roblox Studio 0.744.0.7441077 (version-7aaa6838d36c4448).

- HTML page: https://rapi.sleaze.dev/enums/CompletionAcceptanceBehavior/
- Roblox documentation: https://create.roblox.com/docs/reference/engine/enums/CompletionAcceptanceBehavior

Controls how the Script Editor inserts or replaces text when an autocomplete suggestion is accepted with Enter or Tab.

## Items

| Name | Value | Description |
| --- | --- | --- |
| `Insert` | 0 | Accepting a completion with either Enter or Tab inserts the suggestion without replacing existing text after the cursor. |
| `Replace` | 1 | Accepting a completion with either Enter or Tab replaces existing text after the cursor with the full suggestion text. |
| `ReplaceOnEnterInsertOnTab` | 2 | Pressing Enter replaces existing text after the cursor; pressing Tab inserts without replacing text after the cursor. |
| `InsertOnEnterReplaceOnTab` | 3 | Pressing Enter inserts without replacing text after the cursor; pressing Tab replaces text after the cursor. This is the default of [`Studio.AutocompleteAcceptanceBehavior`](https://rapi.sleaze.dev/classes/Studio.md). |

## Used by

Each entry lists the class, then the role and names of the members that use this type.

- [Studio](https://rapi.sleaze.dev/classes/Studio.md): property `AutocompleteAcceptanceBehavior`
