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

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

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

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

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

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

Library:    CT1.LIB


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

Examples:   * Counting leading spaces.
            ? COUNTLEFT("   123")               && Result: 3

            * Counting the characters ".".
            ? COUNTLEFT("..4.123",".")          && Result: 2

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



See Also: COUNTRIGHT()

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