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


Syntax:     DTOC(<expD>)

Purpose:    To convert a date value to a character string.

Argument:   <expD> is the date value to convert.

Returns:    A character string.

            DTOC() returns a character string representation of a date
            value based on the DATE and CENTURY SETtings.  (See SET DATE
            for the supported formats.)  The default format return value
            is in the form "mm/dd/yy."  A null date returns a string of
            eight or ten spaces depending on whether CENTURY is OFF or
            ON.

Usage:      DTOC() is primarily useful for formatting purposes when you
            want to display the date in the SET DATE format and a
            character expression is required (in a LABEL FORM, for
            example).  If you need a specialized date format, you can
            use TRANSFORM() or a custom expression.

            If you are INDEXing a date as a part of a compound key, use
            DTOS() instead of DTOC().

Library:    CLIPPER.LIB


----------------------------------- Examples -------------------------------

   ? DATE()                               && Result: 09/01/87
   ? DTOC(DATE())                         && Result: 09/01/87
   ? "Today is " + DTOC(DATE())           && Result: Today is 09/01/87


See Also: SET CENTURY SET DATE CTOD() DTOS() TRANSFORM()

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