I’m using a tool (abcm2ps) that generates a PostScript file. It lets me add custom postcript code. Right now I know how to add a footer on the first page. Like this:
/cpr {
0 eq { % first page only
gsave
/Arial 9 selectfont
300 30 moveto % center the text
(Footer) showc
grestore
} if
} def
<< /BeginPage { cpr } >> setpagedevice
How can I add the footer on the LAST page only?
Thanks!
You need to know how many pages are in the PostScript program, if you don’t know that, then you can’t add the footer on the ‘last’ page. If your file is DSC-compliant it will tell you how many pages are in it.