Choose where you’d like to start

removeLastOccurence()

Overview

The removeLastOccurence() function takes string and searchString as arguments. It returns the string after removing the last occurrence of searchString from it.

If the searchString is not present in the string, it will return the string as it is.

Note:  This function performs a case-sensitive search.

Return Type

  • Text

Syntax

<variable> = <string>.removeLastOccurence(<searchString>);

(OR)

<variable> = removeLastOccurence( <string>, <searchString>);
ParameterDescriptionData type
<variable>Variable which will contain the returned string.TEXT
<string>The string from which the searchString's last occurrence will be removed.TEXT
<searchString>


The searchString whose last occurrence will be removed from the string.

TEXT

Examples

Product="Create an app using Zoho Creator app builder";
newText = Product.removeLastOccurence("app");                  
// returns "Create an app using Zoho Creator builder"

Get Started Now

Execute