• Announcements

    • xper

      MSFN Sponsorship and AdBlockers!   07/10/2016

      Dear members, MSFN is made available via subscriptions, donations and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, become a site sponsor and ads will be disabled automatically and by subscribing you get other sponsor benefits.
Sign in to follow this  
Followers 0
golf89

How to change Ghostscript output file (in printer spooler)

6 posts in this topic

I am using Ghostscript to print a PDF by command line arguments. But it shows the printed document's name as Ghostscript output in printer spooler. I want to change it to a custom name .

for that i have tried a command :

gswin32c -dNOPAUSE -dBATCH -c "mark /UserSettings <</DocumentName (MyDocName)>> (mswinpr2) finddevice putdeviceprops setdevice" -f -sOutputFile="%printer%Test" "-sPAPERSIZE=a4 test.pdf

it is solving the problem but creating a new ie. it always give "letter" as the output page size

so suggest me the way by which i can achieve both goals

Thanks

Edited by golf89
0

Share this post


Link to post
Share on other sites

"-sPAPERSIZE=a4" option should work on your command line according to different ghostscript manual.

Edited by allen2
0

Share this post


Link to post
Share on other sites

... there are 5 quotes ("), that is one quote too much or one too many. +there should probably be a space before -s.

0

Share this post


Link to post
Share on other sites

yeah the extra quote is a mistake and that is not even working with a space after -s.

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

  • Recently Browsing   0 members

    No registered users viewing this page.