CT_WORDONE

 WORDONE()
 Reduces the multiple appearances of particular double characters to one
------------------------------------------------------------------------------
 Syntax

     WORDONE([<cDoubleCharacter>],<cString>) --> cString

 Arguments

     <cDoubleCharacter>  Designates which 2-byte sequences are only to
     appear once together in <cString>.  The default value is for all 2-byte
     sequences.

     <cString>  Designates a string that has only specific 2-byte
     sequences that appear together after manipulation.

 Returns

     WORDONE() returns the modified character string.

 Description

     A unique operation is carried out on a string that is constructed out of
     2-byte sequences ("words").  The multiple sequence appearances must lie
     immediately beside one another, which allows a CHARSORT() with an
     element length of 2 to be executed.

     These sequences can be integers that have been generated using the
     Clipper I2BIN() function and have been deposited in a string.  In
     conjunction with other string functions like WORDONLY(), WORDONE() is an
     extremely effective system for working with these kinds of files.

 Note

     .  The term "word" is not used here in the textual sense, but
        rather as it is used in assembler programming.  A "word" consists of
        units of 16 bits, or more precisely, 2 bytes.

 Examples

     .  This is a simple example with characters that can be
        displayed.  The "AB" lie one after the other but not the "12":

        ? WORDONE("12ABAB12")             // "12AB12"

     .  The function always runs through the string in ordered pairs:

        ? WORDONE("12", "1212ABAB")       // "12ABAB"

See Also: CHARONE()



Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.