FT_YEAR

FT_YEAR()
 Return calendar or fiscal year data

 Syntax

      FT_YEAR( [ <dGivenDate> ] ) -> aDateInfo

 Arguments

     <dGivenDate> is any valid date in any date format.  Defaults
     to current system date if not supplied.

 Returns

     A three element array containing the following data:

        aDateInfo[1] - The year as a character string "YYYY"
        aDateInfo[2] - The beginning date of the year
        aDateInfo[3] - The ending date of the year

 Description

     FT_YEAR() returns an array containing data about the year
     containing the given date.

     Normally the return data will be based on a year beginning
     on January 1st.

     The beginning of year date can be changed by using FT_DATECNFG(),
     which will affect all subsequent calls to FT_YEAR() until another
     call to FT_DATECNFG().

     The beginning of year date may be reset to January 1 by calling
     FT_DATECNFG() with no parameters.

 Examples

     // Get info about year containing 9/15/90, assuming default
     // beginning of year is January 1st.
     aDateInfo := FT_YEAR( Ctod("09/15/90") )
     ? aDateInfo[1]   //  1990
     ? aDateInfo[2]   //  01/01/90     beginning of year
     ? aDateInfo[3]   //  12/31/90     end of year

     // get info about current year (1991).
     aDateInfo := FT_YEAR()
     ? aDateInfo[1]   //  1991
     ? aDateInfo[2]   //  01/01/91   beginning of year
     ? aDateInfo[3]   //  12/31/91   end of year

 Source: YEAR.PRG

 Author: Jo W. French dba Practical Computing

See Also: FT_DATECNFG() FT_WEEK() FT_MONTH() FT_QTR()

One response to “FT_YEAR

  1. Pingback: FT Date-Time | Viva Clipper !

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.