PPWIZARD is a free preprocessor for HTML, REXX, Visual Basic or any text files.
[Bottom][Contents][Search][Prev]: Tabs2Spaces()[Next]: ToLowerCase()
\ -> Rexx -> Inbuilt PPWIZARD Functions -> TimeStamp()

TimeStamp()

This is an inbuilt function function provided by PPWIZARD.

This routine returns a string of the form "YYYYMMDDHHMMSS" which represents a time.

If no parameters are passed then the current time is returned. Parameters are:

  1. A time offset. This parameter is optional. This is made up of space separated words such as "2w 3d 7h 1" which represents a time offset (in this case 2 weeks, 3 days, 7 hours and 1 second). This is added to the current or supplied time.

  2. If it is not blank then this is a valid timestamp to be used as the base time rather than the current time.

The GetFileTimeStamp() routine can be used to get a timestamp for a file.

Example

#DefineRexx ''
   call say 'CURRENT TIME'
   call say '~~~~~~~~~~~~'
   call say '####### NOW     = ' || TimeStamp();
   call say '####### + 1     = ' || TimeStamp(1);
   call say '####### + 1day  = ' || TimeStamp('1d');
   call say '####### + 1d1s  = ' || TimeStamp('1s 1d');

   call say '19991112100000'
   call say '~~~~~~~~~~~~~~'
   call say '####### SUPPLIED= ' || TimeStamp(, "19991112100000");
   call say '####### + 1     = ' || TimeStamp(1, "19991112100000");
#DefineRexx


email me  any feedback, additional information or corrections.
See this page online (look for updates)

[Top][Contents][Search][Prev]: Tabs2Spaces()[Next]: ToLowerCase()


PPWIZARD Manual
My whole website and this manual itself was developed using PPWIZARD (free preprocessor written by Dennis Bareis)
Saturday May 28 2022 at 2:55pm