Here's a section of my code written ages ago to print ZPL to Zebra printers:
DCL        &CMD    TYPE(*CHAR)  LEN(512)
DCL        &ERROR  TYPE(*CHAR)  LEN(1)  
IF         COND(&MOPTN *EQ 03) THEN(DO)           
   CALL       PGM(AXZPO) PARM('SLBARLK' &ERROR &CMD)      
   IF         (&ERROR *EQ '0') THEN(DO)                   
      CALL       QCMDEXC PARM(&CMD 512)                   
   ENDDO                                                  
   CALL       BARSZLK                                     
ENDDO                                                     
However, my CMD is bigger, so it's possible you have truncation/conflict because you define it as 180, put pass using a 512 buffer?
Otherwise it might be your printer config in MAPICS.
Report  . . . . . . . . . . . . . :   SLBARLK                                  
                                                                               
Type information; press Enter.                                                 
                                                                               
Report description  . . . . . . . .   lockheed barcode labels                  
Printer file name . . . . . . . . :   BARPSZLK                                 
Group override . . . . .   MAPICS/DB  MAPICS XA OVERRIDE PRTF - GROUP RECORD   
Allow OUTQ override . . . . . . . .   N                                        
Allow attribute overrides . . . . .   N                                        
                                                                               
Override command  . . . . . . :   OVRPRTF FILE(BARPSZLK) TOFILE(*FILE) SPOOL(*YES) OUTQ(PRT09)                                                               
 
James LeLeux
IT Director: Cherry, Shur-Lok, & SPS Santa Ana
1224 East Warner Avenue
Santa Ana, CA 92705
Cell:  714-929-8063
jleleux@xxxxxxxxxxx
 
-----Original Message-----
From: mapics-l-bounces@xxxxxxxxxxxx [mailto:mapics-l-bounces@xxxxxxxxxxxx] On Behalf Of ARojas@xxxxxxxxxxx
Sent: Thursday, February 11, 2010 4:59 PM
To: mapics-l@xxxxxxxxxxxx
Subject: [MAPICS-L] Using the printer overrides for a custom spool file
I'm looking for CL program that allows me to use the printer override 
defined in Mapics for a custom spool file,  I think the CL should be like 
this:
PGM 
   DCL        VAR(&CMD) TYPE(*CHAR) LEN(180) 
   DCL        VAR(&ERROR) TYPE(*CHAR) LEN(80) 
             CALL       PGM(AXZPO) PARM('OE022PL' &ERROR &CMD) 
                           IF         (&ERROR *EQ '0') THEN(DO) 
                              CALL       QCMDEXC PARM(&CMD 512) 
                           ENDDO 
 
                          CALL       OE022RBKTT 
                          ENDPGM 
but is not working... any help is appreciated ...thanks
Antonio Rojas
Manager Applications Development
Semtech Corp.
Cell.    (805) 216-4651
Office (805) 480-2135
_______________________________________________
This is the MAPICS ERP System Discussion (MAPICS-L) mailing list
To post a message email: MAPICS-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: 
http://lists.midrange.com/mailman/listinfo/mapics-l
or email: MAPICS-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at 
http://archive.midrange.com/mapics-l.
 
As an Amazon Associate we earn from qualifying purchases.