TEXTBEFORE function

Tartalom

# TEXTBEFORE

Returns the text that occurs before the start of given instance of a delimiter substring.

### Szintaxis

TEXTBEFORE( Text [; Delimiter [; Instance Number [; Match Mode [; Match End [; If Not Found ]]]]])

Text: the original text.

Delimiter: (optional) the delimiter. Multiple delimiters can be supplied. If omitted or supplied as an empty string, then returns the error #N/A or the value expressed by If Not Found.

Instance Number: (optional) the instance of the delimiter before which to extract text. The default is 1. A negative number starts searching from the end. Value 0 returns the error #N/A

Match Mode: (optional) set to 1 to perform a case-insensitive match. The default is 0.

Match End: (optional) set to 1 to treat the end of text as a delimiter. The default is 0.

If Not Found: (optional) the value returned if no match is found. The default is #N/A.

Any of the optional arguments can be omitted. An optional argument requires all preceding separators to be present.

### Példák

=TEXTBEFORE("To be or not to be";" be";2;0;0;"@@@") returns the string "To be or not to", taking up to the second instance of the delimiter " be".

=TEXTBEFORE("To be or not to be";"question";1;0;0;"@@@") returns the text "@@@" because the delimiter "question" is not in the source text.

#### Technikai információk

This function is available since LibreOffice 25.8.

This function is NOT part of the Open Document Format for Office Applications (OpenDocument) Version 1.3. Part 4: Recalculated Formula (OpenFormula) Format standard. The name space is

COM.MICROSOFT.TEXTBEFORE

Kapcsolódó témakörök

TEXTBEFORE wiki page.

SZÖVEGÖSSZEFŰZÉS

TEXTSPLIT

TEXTAFTER

Támogasson minket!