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>countright()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
COUNTRIGHT()

Syntax:     COUNTRIGHT(<expC1>[,<expC2>])

Arguments:  <expC1> is the string to be processed.
            <expC2> contains the character that should be counted at
            the end of <expC2> string.

Returns:    A numeric value.
            The number denotes how often the <expC2> character
            appears in an uninterrupted sequence at the end of the
            <expC1> string.

Usage:      Whereas REMRIGHT() removes leading characters from
            <expC1>, COUNTRIGHT() will only determine the number of
            <expC2> characters appearing uninterrupted at the end of
            the <expC1> string.

Notes:      Without the <expC2> argument, spaces will be counted.

Library:    CT1.LIB


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

Examples:   * Counting spaces.
            ? COUNTRIGHT("abc   ")              && Result: 3

            * Counting the characters ".".
            ? COUNTRIGHT("abc.d..",".")         && Result: 2

            * When it is not possible to count anything.
            ? COUNTRIGHT("123456")              && Result: 0



See Also: COUNTLEFT()

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