Language Reference Guide : 4. System Classes : StringObject Class : RightTruncate Method
 
Share this page                  
RightTruncate Method
The RightTruncate method truncates the string starting from the character in the specified ordinal position to the end of the string.
This method has the following syntax:
StringObject.RightTruncate([startposition = integer])
This method has the following parameter:
startposition
Specifies the ordinal position of the character at which you want to begin the truncation. In a string object, characters in the text are numbered from left to right, beginning with number one.
Default: 1
To clear the string, you can specify a startposition of one. If you specify an invalid startposition (one that is less than or equal to zero or greater than the length of the string), no text is truncated (there is no error message in such cases).
Note:  If the StringObject is being displayed in an entry field, the changes made by this method are not visible until the entry field's UpdField method is invoked.