[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

A program to date-stamp print-outs



A better idea than to stick filename and date info into a file is to add it
when printing. Many is the time I've looked at an old printout and wondered
where its file was, or which date it had (to compare with other printouts
of the same file).
Below is the program I wrote to do this. It puts a running header or footer
temporarily into the file, and puts the path, filename, date, and time into
it in very small type, flush right. I find this fairly innocuous. It checks
to see if you already have a running header and/or running footer in the
file, and will use whichever is not already used. (If both are used
already, the program aborts).
It has one drawback: it does a SAve on the onscreen file before printing
it. This is necessary because you want to correlate a printout with
something on disk, not something just temporarily on screen. I decided upon
automatic SAving instead of prompting for input ("do you want to save
what's on screen?") since that could get annoying for a regularly used pgm.
I'd load this onto a key, so that you still have the option of doing a TY
the old fashioned way.

XPLeNCODE v2.0
b-gin [UNTITLED]
{<}SV588,[cr|lf]{>}{<}SV590, {>}{<}SV568,{<}LB{>}{>}{<}SV569,
LB{>}{<}XS568,569,595,570,596{>}[BX_]sa[Q2_]{<}SX01,{<}VA$FP{
>}{>}{<}SX02,{<}VA$FI{>}{>}{<}SV03,$_$_.tmp{>}{<}SX04,{<}VARM
{>}{>}[BX_]es 1[Q2_][BX_]del $_$__.tmp[Q2_][BX_]ne $_$__.tmp[
Q2_]{<}IF{<}ER{>}{>}[BC_]can't open a window for temp file{<}
EX{>}{<}EI{>}[BX_]me {<}PV01{>}[Q2_][XP_][TF_]{<}SX05,0{>}{<}
SX06,0{>}[BX_]sea /{<}PV595{>}RH/[Q2_]{<}IF@NOT({<}ER{>}){>}{
<}SX05,1{>}{<}EI{>}[TF_][BX_]sea /{<}PV595{>}RF/[Q2_]{<}IF@NO
T({<}ER{>}){>}{<}SX06,1{>}{<}EI{>}{<}IF{<}PV05{>}+{<}PV06{>}=
=2{>}[BC_]Aborted--file already has a header and footer{<}EX
{>}{<}EI{>}{<}SV07,RHA{>}{<}IF{<}PV05{>}==1{>}{<}SV07,RFA{>}{
<}EI{>}[BX_]dir {<}PV01{>}[Q2_][BX_]se /_____________________
___________________/[Q2_][BX_]seb /  /[Q2_][RC_][RD_][PW_][D
F_][LE_][DF_]{<}SV08{>}[BX_]ab[Q2_][XP_][TF_]{<}PV595{>}{<}PV
07{>}{<}PV595{>}FR{<}PV596{>}{<}PV595{>}SZ6PT{<}PV596{>}[DF_]
{<}PV01{>}{<}PV590{>}{<}PV590{>}{<}PV08{>}[DF_][CL_][BX_]lc[Q
2_][XD_]{<}SV568,RHA{>}{<}IF{<}IS07{>}=={<}IS568{>}{>}{<}PV58
8{>}{<}PV588{>}{<}PV588{>}{<}EI{>}{<}PV596{>}[BX_]ty[Q2_][BX_
]wait[Q2_][BX_]ab[Q2_][BC_]{<}PR Printing is done.{>}{<}EX{>}
-nd
XPLeNCODE


Harry Binswanger
hb@xxxxxxxx