A version of the Windows "FILE:" port which does not prompt for the file name but autogenerates one
I have a process where one of the things to do is to capture the output from a print into a file for further processing. For this I have configured a "FILE:" printer port which works very nicely but asks everytime for the file name to use.
Unfortunately "FILE" is not a very descriptive word when trying to use a search engine :(
Is there a small driver somewhere which does exactly the same as the FILE: driver, but can automatically generate a fi开发者_StackOverflow社区lename (perhaps based on a pattern) and just print to that?
On the printer properties, port tab, click "Add Port...", "Local port", "New Port..." and then enter a drive path and filename. e.g. "C:\temp\printjob.prn" then click ok, and ok. If you get access denied, use the "Run as admin..." and then select Properties, etc..
That will print the job to that specific filename every time. You can rename the result.
Sadly, you can't (apparently) use %TIME% or %RANDOM% to make a unique filename.
Try Multi File Port Monitor. I have it connected to the Ghostscript PDF printer driver (which is just a PostScript driver). When the driver creates PostScript it gets piped into gswin32 which converts it into pdf. Each generated pdf is given a unique name. You could get the behaviour you require by not piping the data to an external program - that way you'll just get the unique file naming.
The 1.5.1 release has more options than the earlier version. Here's the configuration dialog for 1.5.1:
On my machine the User command text box contains this text:
"C:\Program Files\gs\gs9.21\bin\gswin64c.exe" -dBATCH -dSAFER -dNOPAUSE -sDEVICE=pdfwrite -dPDFSETTINGS=/prepress -dAutoRotatePages=/PageByPage -r600 -sOutputFile="%f" -
Use redmon. This is a file port redirector. It is open-source and has quite a lot of options for configuration. - http://pages.cs.wisc.edu/~ghost/redmon/
The website says it is currently available only for Win XP so if that is your OS you are in luck.
Let me know if you need more help
Hope this is useful. If so +1 :)
精彩评论