Skip to main content

StrLeft function (LotusScript Language)

Searches a string from left to right for a pattern and returns a substring consisting of the characters in the string that are to the left of the pattern.

Syntax

StrLeft ( expression , pattern [, compMethod [, occurrences ]] )

Elements

expression

A String to search for the specified pattern.

pattern

The String pattern to search for.

compMethod

An Integer specifying which comparison to use.

FlagType of Comparison
0Case Sensitive, Pitch Sensitive
1Case Insensitive, Pitch Sensitive
4Case Sensitive, Pitch Insensitive
5Case Insensitive, Pitch Insensitive

occurrences

Long. Number of occurrences to match before returning the substring. Default = 1 or return on first occurrence found.

Extended example: array and String functions