From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f7344,f30b7a4226aca9b0 X-Google-Attributes: gidf7344,public X-Google-Thread: 1094ba,f30b7a4226aca9b0 X-Google-Attributes: gid1094ba,public X-Google-Thread: 1164f8,f30b7a4226aca9b0 X-Google-Attributes: gid1164f8,public From: Pierre.Bru@spotimage.fr Subject: Re: Date Calculations in Dec Fortran Date: 1999/03/02 Message-ID: <7bgbnu$co4$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 450293224 References: <36DA2562.D3D02A6E@transtech.net> X-Http-Proxy: 1.0 x11.dejanews.com:80 (Squid/1.1.22) for client 194.199.150.1 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Tue Mar 02 09:41:19 1999 GMT Newsgroups: comp.lang.fortran,comp.sys.dec,comp.os.vms X-Http-User-Agent: Mozilla/4.5 [en] (WinNT; I) via proxy gateway CERN-HTTPD/3.0 libwww/2.17 I one write routines called Read_Date_Time and Write_Date_Time (in Pascal not in Fortran) that use RTL function: to read your date: call lib$init_date_time_context with something like |!Y4!MN0!D0|!H04!M0!S0!C2| as input fomat in init-string, then call lib$convert_date_string to convert your date to OpenVMS internal format. at this point, you can do any date/time computation available in RTL. to write your computed date: first call lib$init_date_time_context with |!Y4!MN0!D0|| as init-string but for output format, then call lib$format_date_time to convert the OpenVMS internal date format back to ascii string. feel free to email if you want more info. Pierre In article <36DA2562.D3D02A6E@transtech.net>, Daniel Steinmetz wrote: > Does anyone have routines that manipulate dates and would not mind > sharing them ? I'm interested in subtracting a certain number of days > from todays date (format YYYYMMDD ) and getting the result in a similar > format. > > Thanks in Advance > > Dani Steinmetz > Dani@transtech.net > > System Engineer > Transtech Systems Inc > Miami, FL > > -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own