beautypg.com

Rightstr, Repstr, substr, leftstr, Tstr, reps – Visara Master Console Center Scripting Guide User Manual

Page 174: Htstr, reps

background image

Chapter 5 Script Commands

Scripting Guide

174

RIGHTSTR

Syntax:

RIGHTSTR( $String, %Count) ==> $SubStr

Description:

Returns the right-most specified number of characters of a string

expression.

Action:

A substring is extracted from a string expression beginning with the

last character in the string expression.

Parameters:

$String. String expression. The character string from which to

extract characters.
%Count. Numeric expression. The number of characters to extract. If
Count is negative or zero, RIGHTSTR() returns an empty string “”. If

Count is larger than the length of String, RIGHTSTR() returns the
entire String.

Returns:

String value. The rightmost Count characters of String as a character

string.

Notes:

N/A

Example:

$Var := RIGHTSTR( $Msg, 4)

See Also:

ATSTR, FINDSTR, LEFTSTR, REPSTR, STR, SUBSTR