[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 CTODOW()
 Converts the name of the day of the week into a corresponding number
------------------------------------------------------------------------------
 Syntax

     CTODOW(<cDayofWeek>) --> nDayofWeek

 Argument

     <cDayofWeek>  Designates a character string that contains the name
     of a day of the week.

 Returns

     CTODOW() returns the number of the day for the day name.

 Description

     Use CTODOW() to change the name of a day of the week to a number.
     Sunday corresponds to 1, Monday 2, etc..  If the function returns a 0
     value, an invalid parameter has been passed.  You can shorten the day
     names, but these abbreviations must be explicit to return an accurate
     value.

 Notes

     .  Uppercase and lowercase letters do not affect the name of the
        day of the week.

     .  The function's operation depends on the country-specific
        adaptation of your CA-Clipper compiler.  With an English version of
        CA-Clipper, only English day names are recognized.

 Examples

     .  What number of the day of the week is Sunday?

        ? CTODOW("Sunday")         // Result:  1

     .  Show several ways to get the day of the week for Wednesday:

        ? CTODOW("WEDNESDAY")      // Result:  4
        ? CTODOW("Wednesday")      // Result:  4
        ? CTODOW("Wed")            // Result:  4

     .  What number of the day of the week is Monday?

        CTODOW("M")                // Result:  2


See Also: NTOCDOW()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson