>  Docs Center  >  Libraries  >  JHU/APL/S1R  >  YMD2DATE
Libraries

YMD2DATE

YMD2DATE

Name


      YMD2DATE

Purpose


      Convert from year, month, day numbers to date string.

Category


Calling Sequence


      date = ymd2date(Y,M,D)

Inputs


      y = year number (like 1986). in
      m = month number (1 - 12). in
      d = day of month number (1 - 31). in

Keyword Parameters


Keywords


        FORMAT = format string. Allows output date to be customized.
            The following substitutions take place in the format string:
        Y$ = 4 digit year.
        y$ = 2 digit year.
        N$ = full month name.
        n$ = 3 letter month name.
        d$ = day of month number.
        0d$ = day of month number with leading 0 if < 10.
        W$ = full weekday name.
        w$ = 3 letter week day name.

Outputs


      date = returned date string (like 24-May-1986). out

Common Blocks


Notes


Notes


        The default format string is 'd$-n$-Y$' giving 24-Sep-1989
        Example: FORMAT='w$ N$ d$, Y$' would give 'Mon

Modification History


      R. Sterner. 16 Jul, 1986.
      RES 18 Sep, 1989 --- converted to SUN
      R. Sterner, 28 Feb, 1991 --- modified format.
      R. Sterner, 16 Dec, 1991 --- added space to 1 digit day.
      R. Sterner, 1996 Jan 5 --- Added leading 0 to day of month.
      R. Sterner, 1999 Aug 04 --- Improved the Y2K fix.
      Johns Hopkins University Applied Physics Laboratory.
  Copyright (C) 1986, Johns Hopkins University/Applied Physics Laboratory
  This software may be used, copied, or redistributed as long as it is not
  sold and this copyright notice is reproduced on each copy made. This
  routine is provided as is without any express or implied warranties
  whatsoever. Other limitations apply as described in the file disclaimer.txt.



© 2024 NV5 Geospatial Solutions, Inc. |  Legal
   Contact Us