Previous Thread
Next Thread
Print Thread
PRINTER.INI question #1610 11 Apr 18 12:57 PM
Joined: Sep 2002
Posts: 5,471
F
Frank Online Content OP
Member
OP Online Content
Member
F
Joined: Sep 2002
Posts: 5,471
Good day -

ATE -> Linux setup.

If we are using file commands to try to line up a label printer, do we have to exit ashell after every change? Or does ashell process the .INI file from scratch every time.

TIA.

FOLLOWUP QUESTION:

When the docs say that a certain option is Windows only, does that mean it will still work with ATE?

Re: PRINTER.INI question #1611 11 Apr 18 01:43 PM
Joined: Sep 2002
Posts: 5,471
F
Frank Online Content OP
Member
OP Online Content
Member
F
Joined: Sep 2002
Posts: 5,471
More Followup:

with the LP TRACE=ON

It shows it using ATE0.INI which is local to this PC. Whic is overriding the PRINTER.INI i have set in SYS:

I feel like right church, wrong pew.. or perhaps even wrong church... :rolleyes:

Sample trace:
SPOOL file=C:\Users\SNOEL\Documents\APEX\pat001-2.prt, ptr=ATE0, switches=16777348, copies=1, form=, totpages=0
prefix=, suffix=, overlay=
2 14:38:54 Trace: ATE0.INI : DEVICE= PROMPT:
3 14:38:54 Trace: ATE0.INI : PASSTHROUGH= OFF
4 14:38:54 Trace: ATE0.INI : CRLF= OFF
5 14:38:54 Trace: ATE0.INI : STRIPFF= OFF
6 14:38:54 Trace: ATE0.INI : FORMFEED= OFF
7 14:38:54 Trace: ATE0.INI : PITCH= AUTO
8 14:38:54 Trace: ATE0.INI : CPP= 80,132
9 14:38:54 Trace: ATE0.INI : LPP= 66
lpp=66, cpp=80, cppw=132, width=0, tmar=0, lmar=0, fnh=-9999, fnw=0, land=0, flags=0x40004
11 14:38:54 GetDefaultPrinter1 (from last-used in registry): Brother QL-500
12 14:38:54 Verifying last used printer (retrieving handle) [Brother QL-500]...
13 14:38:54 ClosePrinter(a98d4c)
14 14:43:55 PrintDlgEx (from COMDLG32.DLL): 0x75384b96, hr=0, e=-1, action=cancel, copies=1

Re: PRINTER.INI question #1612 12 Apr 18 10:23 AM
Joined: Sep 2002
Posts: 5,471
F
Frank Online Content OP
Member
OP Online Content
Member
F
Joined: Sep 2002
Posts: 5,471
Ok left to my own recognizance (no thanks to Herman...) i recalled a way to embed //GDI commands as part of the PREFIX command in the printer.ini file.

So i created a label.gdi file and linked it using PREFIX=SYS:LABEL.GDI.

This sees to work.

My only complaint if you want to call it that is that in the documentation for the printer.ini files is that the mention of "windows only" commands doesn't clarify WINDOWS SERVER vs an ATE/windows environment. Might help others from falling into the wrong pew in the future.

Re: PRINTER.INI question #1613 12 Apr 18 11:54 AM
Joined: Jun 2001
Posts: 11,794
J
Jack McGregor Offline
Member
Offline
Member
J
Joined: Jun 2001
Posts: 11,794
I feel your pain.

There is invariably some confusion between Windows vs UNIX, and Windows server vs ATE, especially in printing, where the operation may spread over the two domains.

To start with your first question, if you are talking about printer INI files, they definitely get processed each time you print. (As an aside, recall that because "INI" files were easily confused due to their varying purposes, we introduced "PQI" files, for Print Queue Initialization, as an unambiguous alternative, although A-Shell continues to support either xxxxxx.PQI[1,7] or xxxxxx.INI[1,4] for printer initialization, in that order. Typically in the doc we try to refer to these generically as "printer init files".)

When printing to ATE, typically the only thing that needs to be in the server-side printer init file is the DEVICE statement redirecting the operation to the AUXLOC: device, e.g.:

DEVICE=AUXLOC:

or, to specific a particular client-side init file, in this case called LABEL:

DEVICE=AUXLOC:LABEL

In the latter example, ATE would try to use LABEL.PQI[1,7] or LABEL.INI[1,4] for the client-side printer initialization.

In the former example, where there is no explicit name given for the client-side printer, ATE creates an ATE0.INI file with the default settings you see in the trace.

If it were me, I would create a LABEL.PQI file for the label printer, and put the PREFIX=ASHCFG:LABEL.GDI statement in there. And then I would add some logic to my application to sync master copies of those files from the server to the ATE clients, either at startup, or perhaps just before printing.

As I think of it now, perhaps it might be nice if there was a mechanism to do that sync operation automatically, perhaps by embedding some directive into the server-side printer init file. But wait: there already is such a mechanism: the COMMAND=SBX: directive. (I wonder if anyone has been clever enough to use that approach?)

As for your directions to get to church, I'm as confused as you are. When you refer to your PRINTER.INI in SYS:, which side of the denominational divide are you on?

If you're talking about a server-side SYS:PRINTER.INI, and it contains a statement like DEVICE=AUXLOC:LABEL, then indeed, that should tell ATE to use the printer init file LABEL.PQI or LABEL.INI. If neither of those existed, then the trace would complain about it, rather than just revert to the ATE0.INI. So I'm guessing that your SYS:PRINTER.INI contained only DEVICE=AUXLOC:, or you were referring to a PRINTER.INI on the client side of the aisle?

Re: PRINTER.INI question #1614 12 Apr 18 01:50 PM
Joined: Sep 2002
Posts: 5,471
F
Frank Online Content OP
Member
OP Online Content
Member
F
Joined: Sep 2002
Posts: 5,471
Lol.. well i was just referring the the ashell/server side of the aisle.. well call it the grooms side wink

It was just confusing as to what commands or gifts i could bring to the grooms side. But alas, the bride didn't care for any of this, so i had to start over. To be honest, syncing INI files would be OK but i much prefer my grooms side solution of just marrying the 2 and declaring it a done deal from the server side.

As an aside, you are very right, keeping these as .INI files does create some legacy confusion for us old timers... (and to just beat Herman to it... where was my tapioca :rolleyes: )


Moderated by  Jack McGregor, Ty Griffin 

Powered by UBB.threads™ PHP Forum Software 7.7.3