<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: LP Command Script Writing Sequential Number on Spool File in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364848#M194673</link>
    <description>Modify the print driver script (if you are using "lp" command, then you can find it at&lt;BR /&gt;/usr/spool/lp/interface/model.orig/printer)&lt;BR /&gt; &lt;BR /&gt;You can add code to redirect the output to a file here.&lt;BR /&gt; &lt;BR /&gt;HTH&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
    <pubDate>Wed, 25 Aug 2004 11:29:59 GMT</pubDate>
    <dc:creator>Rodney Hills</dc:creator>
    <dc:date>2004-08-25T11:29:59Z</dc:date>
    <item>
      <title>LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364841#M194666</link>
      <description>Hello. I am trying to figure out how do I use the lp command to print to a file that names it for example, sp1.spl, sp2.spl, sp3.spl, sp4.spl, etc...and put it into a directory (/printer/spool). Any help is appreciated. Thanks.</description>
      <pubDate>Wed, 25 Aug 2004 10:47:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364841#M194666</guid>
      <dc:creator>Son Le_1</dc:creator>
      <dc:date>2004-08-25T10:47:52Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364842#M194667</link>
      <description>As you've stated the problem, the answer would be &lt;BR /&gt;&lt;BR /&gt;cp sp?.spl /printer/spool&lt;BR /&gt;for i in /printer/spool/*&lt;BR /&gt;do&lt;BR /&gt;lp /printer/spool/$i&lt;BR /&gt;done&lt;BR /&gt;&lt;BR /&gt;I'm sure that's more simplistic than you intended.  Could you expand on your requirements?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Wed, 25 Aug 2004 10:55:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364842#M194667</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2004-08-25T10:55:54Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364843#M194668</link>
      <description>I have a software in HP-UX 11.0 that uses a printer open command. The thing I am trying to do is when I print something in this software that it spools to a file and start naming it sequential after that. As of right now, when I print something to file, it goes to a file called, file.prt. This however gets overwritten each time I print to file. That is why I am trying to use the lp command to print to file so that if I do multiple print, that it doesn't get overwritten. Thanks for your help.</description>
      <pubDate>Wed, 25 Aug 2004 11:00:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364843#M194668</guid>
      <dc:creator>Son Le_1</dc:creator>
      <dc:date>2004-08-25T11:00:18Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364844#M194669</link>
      <description>So, is this software that uses a "printer open command" a compiled program or a shell script?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Wed, 25 Aug 2004 11:07:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364844#M194669</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2004-08-25T11:07:08Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364845#M194670</link>
      <description>its a compile program...its called Eldorado. It is programmed in dbc. If i enter in lp -dis2 -olandscape in the open command field, it will print whatever I request to the printer IS2.</description>
      <pubDate>Wed, 25 Aug 2004 11:12:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364845#M194670</guid>
      <dc:creator>Son Le_1</dc:creator>
      <dc:date>2004-08-25T11:12:44Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364846#M194671</link>
      <description>Sorry, I can't think of a way to change the behaviour of a compiled program when you have such limited input to it.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Wed, 25 Aug 2004 11:15:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364846#M194671</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2004-08-25T11:15:53Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364847#M194672</link>
      <description>I tried the lp /print/spool/$i and it didn't work. The printer open command is just something that I can either put in a lp command in or any command actually that you can do in unix. What is the command to output something to a file, i know you use "&amp;gt;&amp;gt;" without the quotation to output something.</description>
      <pubDate>Wed, 25 Aug 2004 11:21:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364847#M194672</guid>
      <dc:creator>Son Le_1</dc:creator>
      <dc:date>2004-08-25T11:21:32Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364848#M194673</link>
      <description>Modify the print driver script (if you are using "lp" command, then you can find it at&lt;BR /&gt;/usr/spool/lp/interface/model.orig/printer)&lt;BR /&gt; &lt;BR /&gt;You can add code to redirect the output to a file here.&lt;BR /&gt; &lt;BR /&gt;HTH&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Wed, 25 Aug 2004 11:29:59 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364848#M194673</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2004-08-25T11:29:59Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364849#M194674</link>
      <description>there are a lot of codes in there....what exactly do I have to write in there. Thanks.</description>
      <pubDate>Wed, 25 Aug 2004 11:48:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364849#M194674</guid>
      <dc:creator>Son Le_1</dc:creator>
      <dc:date>2004-08-25T11:48:27Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364850#M194675</link>
      <description>If this print queue is not to an actual printer. You can delete most all the code in the driver and place what you want in it. Keep the code up to where variable "files" is set.&lt;BR /&gt;&lt;BR /&gt;I incorrectly told you the wrong driver file, it is /usr/spool/lp/interface/printer.&lt;BR /&gt; &lt;BR /&gt;You may want to brush up on your shell script programming. &lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Wed, 25 Aug 2004 12:08:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364850#M194675</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2004-08-25T12:08:18Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364851#M194676</link>
      <description>Use the 'dumb' model script as a start. What you need to create is a printer script that does not actually print but instead, directs the output to a file. Printer scripts are a bit complex if you haven't done much scripting before. Your script will be given several command line options, then you would create the appropriate filename. NOTE: the printer script is run only when you run the program so it has no memory of previously created files. The script would have to look at the files already created and pick the next name. The name of the print file created by your program will be on the command line, you just cat that file and redirect it into your directory with sp1.spl, sp2.spl, sp3.spl, etc.&lt;BR /&gt; &lt;BR /&gt;Once the script is working locally, you would add it to the spooler using lpadmin. The output printer device will be /dev/null.</description>
      <pubDate>Wed, 25 Aug 2004 13:58:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364851#M194676</guid>
      <dc:creator>Bill Hassell</dc:creator>
      <dc:date>2004-08-25T13:58:05Z</dc:date>
    </item>
    <item>
      <title>Re: LP Command Script Writing Sequential Number on Spool File</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364852#M194677</link>
      <description>i was hoping I didn't have to program anything but I guess thats my only option. Thanks for the effort.</description>
      <pubDate>Thu, 26 Aug 2004 10:29:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/lp-command-script-writing-sequential-number-on-spool-file/m-p/3364852#M194677</guid>
      <dc:creator>Son Le_1</dc:creator>
      <dc:date>2004-08-26T10:29:27Z</dc:date>
    </item>
  </channel>
</rss>

