LSTSRV-L Archives

LISTSERV Site Administrators' Forum

LSTSRV-L

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Ross Patterson <A024012@RUTVM1>
Mon, 12 Oct 87 09:32:41 EDT
text/plain (22 lines)
It shouldn't be hard to parse out the Date: line in a Rexx exec, and
you already have the "set the date and time" program - LSVSDATE, shipped
as part of LISTSERV. Syntax is "LSVSDATE <fn> <ft> <fm> <yymmdd> <hhmmss>".
Yes, that's "yymmdd", not "mmddyy". Remember, Eric lives in France ;-)
Try something like:
 
/* FIXDATE EXEC - syntax: FIXDATE <fn> <ft> <fm> */
Arg FN FT FM .;
'EXECIO * DISKR' FN FT FM '(STEM L.';
Do I = 1 to L.0;
   Parse upper var L.I Resent? 'DATE:' Day ',' DD Month YY HH ':' MM ':' SS .;
   If L.I = '' then Leave;
   If Resent? ^= '' & Resent ^= 'RESENT-' then Iterate;
   MM = Find(Mon,'JAN FEB MAR APR MAY JUN JUL AUG SEP OCT NOV DEC');
   If MM = 0 then Leave;
   'LSVSDATE' FN FT FM YY || MM || DD HH || MM || SS;
   If RC ^= 0 then Say 'Error(' || RC || ') from LSVSDATE';
   Exit RC;
End;
Say 'Couldn't find Date: or Resent-Date: in headers of' FN FT FM;
Exit 100;

ATOM RSS1 RSS2