Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Clipper Tools One Guide - <b>replright()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
REPLRIGHT()

Syntax:     REPLRIGHT([@]<expC1>,<expC2>[,<expC3>])

Arguments:  <expC1> is the string to be processed.
            <expC2> is the character used to replace all <expC1> at the
            end of the <expC1> string.
            <expC3> is the character to be replaced by <expC2> at the
            end of <expC1>.

Returns:    A character string.
            The processed <expC1> string.

Usage:      REPLRIGHT() can ,for example, be used to replace the
            trailing spaces in a string by any other character.

Notes:      The function will assume spaces are to be replaced in the
            absence of the <expC3> argument.

Library:    CT1.LIB


--------------------------------- Example ------------------------------

Examples:   * Replacing the space at the end with
            * by hyphens.
            ? REPLRIGHT("abcd  ","-")                     && "abcd--"

            * Replacing hyphens at the end
            * with spaces.
            ? REPLRIGHT("abcd--"," ","-")                 && "abcd  "

            * Only the characters at the end
            * are replaced.
            ? REPLRIGHT("  d  ","-")                      && "  d--  "



See Also: REPLALL() REPLLEFT()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson