Left
Description:
Format:
Left (string Source, integer Length)
|
Parameters: |
Stringr |
Source |
Source string from which to copy characters. |
|
Integer |
Length |
Number of characters to copy from Source. |
|
|
Return Value: |
String |
Result |
String consisting of copied characters. |
Usage:
Example 1:
Assign strResult the first 5 characters from the current document's title.
String strResult
strResult = Left(GetDocumentTitle(), 5)
Example 2:
String strPhrase
String strResult
strPhrase = 'Super Widgets, Long Widgets, Soft Widgets'
strResult = Left(strPhrase, Pos(strPhrase, ',') - 1)