Variable print file name
Bill Randall
wrandall at fptech.com
Wed Apr 8 14:54:53 PDT 2015
PDF:|cat>/u/appl/fpmerge/ReporteFP/$$.pdf
Bill
On 4/8/2015 5:36 PM, Mike Schwartz wrote:
> How can I set the destination file to a variable name?
>
> In this case I have created an entry on printer maintenance screen called
> Kentest.
> Type is :fpml Destination : PDF:/u/appl/fpmerge/ReportsFP/ xtest.pdf
> That works fine. But how can filepro create a variable file name in that
> directly?
> Of course this is only from printer maintenance screen.
>
> Ken Wakeman
> ----- ---- ----------
>
> I hope I correctly snipped all the code out of your HTML message.
> (above).
>
> You're not telling us which version of filePro you are using, nor which
> operating system (Unix, Windows, etcetera). However, here is some code that
> works for me to print a customer statement on filepro 5.7.03 running on Sco
> Openserver 6. The processing is attached to a form called statementPDF.
> (That is the PDF version of an invoice form for one of my customers.)
>
> You could write this as a subroutine and skip all the XG XH nonsense.
> XA allows the billing clerks to name the output processing whatever they
> want. Statements get deleted within a few seconds, right after they are
> emailed, so I'm not too worried about duplicate PDF names.
>
> 5 ------- - - - - - - - - - - - - - - - -
> þ If: XG=""
> Then: input popup xa "Please type in a SHORT description of this
> statement:"
> 6 ------- - - - - - - - - - - - - - - - -
> þ If: XG=""
> Then: XB=xlate(xa," '&,","____") 'Remove odd characters from title
> 7 ------- - - - - - - - - - - - - - - - -
> þ If: XG=""
> Then: XG(60,*,g)="/u1/images/" {XB {"_Statement.pdf"
> 8 ------- - - - - - - - - - - - - - - - -
> þ If: XH="" 'Create the file
> Then: system "touch" <XG
> 9 ------- - - - - - - - - - - - - - - - -
> þ If: XH="" 'Chmod it
> Then: system "chmod a+rw" <XG
> 10 ------- - - - - - - - - - - - - - -
> þ If: XH="" 'Chown it
> Then: system "chown filepro" <XG
> 11 ------- - - - - - - - - - - - - - -
> þ If: XH=""
> Then: PRINTER "PDF:>" {XG 'Create the PDF statement
> 12 ------- - - - - - - - - - - - - - - - -
> þ If:
> Then: XH(1,*,g)="X" 'Make sure PDF line only executes
> once
>
> Mike Schwartz
>
>
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> Subscribe/Unsubscribe/Subscription Changes
> http://mailman.celestial.com/mailman/listinfo/filepro-list
>
---
This email has been checked for viruses by Avast antivirus software.
http://www.avast.com
More information about the Filepro-list
mailing list