# TEXTAFTER

## Content

This function <span style="color: rgb(23, 43, 77); font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Fira Sans, Droid Sans, Helvetica Neue, sans-serif; font-size: 16px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: -0.08px; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: pre-wrap; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255); text-decoration-thickness: initial; text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;">returns text that occurs after a given character or string. </span>

## Syntax

`TEXTAFTER(text,delimiter,[instance_num], [match_mode], [match_end], [if_not_found])`

## Arguments

The function has the following arguments:

| Argument | Description |
| -------- | ----------- |
| *text* | Refers to the text you are searching within. Wildcard characters are not allowed. |
| *delimiter* | Refers to the text that marks the point after which you want to extract. |
| *instance\_num* | [Optional] Refers to the instance of the delimiter after which you want to extract the text.  <br>By default, instance\_num = 1. In case of a negative number, the text is searched from the end. |
| *match\_mode* | [Optional] Determines whether the text search is case-sensitive. The default is case-sensitive. You can enter one of the following:<ul><li>**0**      Case sensitive.</li><li>**1**      Case insensitive</li></ul> |
| *match\_end* | [Optional] Treats the end of the text as a delimiter. By default, the text is an exact match. You can enter one of the following:<ul><li>**0**      Don't match the delimiter against the end of the text</li><li>**1**      Match the delimiter against the end of the text</li></ul> |
| *if\_not\_found* | [Optional] Refers to the value returned if no match is found. By default, #N/A is returned. |

## Data Types

Returns string data.

## Remarks

The TEXTAFTER function matches immediately when searching using an empty delimiter value. It returns the entire text when searching from the front (if instance\_num is positive) and, empty text when searching from the end (if instance\_num is negative).

## Examples

```JavaScript
=TEXTAFTER("Little red Riding Hood's red hood","red") // result is "Riding Hood's red hood"
=TEXTAFTER("Little red Riding Hood's red hood","red", 2) // result is "hood"
=TEXTAFTER("Little red Riding Hood's red hood","Red") // result is #N/A
=TEXTAFTER("Little red Riding Hood's red hood","Red", ,1) // result is "Riding Hood's red hood"
```