Sponsored Content
Operating Systems AIX Print to Windows PDF printer from AIX Post 302936443 by jgt on Wednesday 25th of February 2015 01:44:47 PM
Old 02-25-2015
Code:
     1  #!/usr/bin/ksh                                              
     2  #email pay stub to employee, as password protected pdf and  
     3  #store pdf file in pay period folder in payhistory folder   
     4  EMAIL=$1                                                    
     5  PERIOD=$2                                                   
     6  EMPL=$3                                                     
     7  PASSWORD=$4                                                 
     8  PAYSTUB=$6                                                  
     9  EMAILFLAG=$5                                                
    10  PAYROLL=$7                                                  
    11  echo $1 $2 $3 $4 $5 $6 $7 >>email.log                       
    12  if [ ! -d payhistory ]                                      
    13  then                                                        
    14          mkdir payhistory                                    
    15          chmod 0755 payhistory                               
    16  fi                                                          
    17  if [ ! -d payhistory/$PAYROLL ]                             
    18  then                                                        
    19          mkdir payhistory/$PAYROLL                           
    20          chmod 0755 payhistory/$PAYROLL                      
    21  fi                                                          
    22  if [ ! -d payhistory/$PAYROLL/$PERIOD ]                     
    23  then                                                        
    24          mkdir payhistory/$PAYROLL/$PERIOD                   
    22  if [ ! -d payhistory/$PAYROLL/$PERIOD ]                  
    23  then                                                     
    24          mkdir payhistory/$PAYROLL/$PERIOD                
    25          chmod 0755 payhistory/$PAYROLL/$PERIOD           
    26  fi                                                       
    27  /usr/gnu/bin/enscript -f Courier10 -p - <$PAYSTUB |\     
    28  ps2pdf  -  payhistory/$PAYROLL/$PERIOD/$EMPL.pdf

Make "payhistory" a shared folder (Samba/NFS) and replace enscript with your script that assembles the Postscript file.
 

9 More Discussions You Might Find Interesting

1. AIX

AIX 5.2 print to a local printer

HHi guys . I have this problem ,I'm trying to print to a local machine (windows from the aix box , I;m using tiny Term Emulator) I mean i have no idea what should i do to get this going. The printer is connect it to the pc , it does not have an ip address. Thanks a lot Jose (0 Replies)
Discussion started by: josramon
0 Replies

2. UNIX for Advanced & Expert Users

Configure SCO Unix to print on windows base XP printer

Hi, I have done this year ago, and now I need to do it again, but did not remember how I do it. I have a slip printer on a windows xp workstation and i need to print from SCO unix application to that printer. I try to create a remote printer but the only option available is unix, the other to... (0 Replies)
Discussion started by: comsiconsa
0 Replies

3. UNIX Desktop Questions & Answers

wt is the exact procedure to share windows printer on linux machine to print from it

hi, what is the exact procedure to to set up printer on linux machine?The printer is a network hp 3050 printer configured on windows xp machine and i want to setup it on linux fc9 machine to print from it.is samba is compulsory for that? please give the exact procedure to do the same? (1 Reply)
Discussion started by: pankajd
1 Replies

4. AIX

Check printer queue on Windows printer server

Hello Let me first give a small overview of the setup. All printers are connected to Windows 2000 servers. There are a lot of UNIX (AIX & HP-UX) servers as well which have SAP running. I'm working on a script to add printers to a specified SAP instance. I want to verify the user input (to... (0 Replies)
Discussion started by: NielsV
0 Replies

5. UNIX for Dummies Questions & Answers

smbclient print while preserving windows printer settings?

I have successfully gotten AIX to print to a windows shared printer with this command: smbclient -U user%password -W domain -c "print file.ext" the only problem is: I have this print queue set up on the Windows side to overlay an image to all pages. When printing from samba, the overlay... (2 Replies)
Discussion started by: raidzero
2 Replies

6. AIX

AIX printer and extra blank page after each print

Guy's I have installed AIX direct Network printer as the below details.... printer1 hp@printer1 hplj-3 (HP-GL/2) Printer is printing fain and clearly but it's printing extra blank page after each print ? What's the couse of this problem ? Pls advice ! (6 Replies)
Discussion started by: ITHelper
6 Replies

7. AIX

Create pdf printer queu

I need to create a print queue in AIX to be able to print directly to pdf (or a network based printer) from a informix based application (Genero/FourJ). I have a AIX 5.3 a I canīt find any documentation for this. If possible I would not like to use any thirth party software. Can someone help me on... (2 Replies)
Discussion started by: marques_rmc
2 Replies

8. AIX

How to print PDF files on AIX 5.3?

Hello All, How to print PDF files on AIX 5.3 and 6.1 because i tried adobe reader with no success, any help will be highly appreciated. Thank you (8 Replies)
Discussion started by: moudmm
8 Replies

9. UNIX for Beginners Questions & Answers

Remote print from SLES (SAP) to AIX 7.1 04 sp2 virtual printer queue gets down

Hello Administrators. I have a bit difficult problem. I have local virtual printer that has backend defined in /etc/qconf to script which in turns sends the spool to the real device. whenever I print locally (from sap) the print works as it should. The printer queue after the print is done... (6 Replies)
Discussion started by: Deneth
6 Replies
GZEXE(1)                                                      General Commands Manual                                                     GZEXE(1)

NAME
gzexe - compress executable files in place SYNOPSIS
gzexe name ... DESCRIPTION
The gzexe utility allows you to compress executables in place and have them automatically uncompress and execute when you run them (at a penalty in performance). For example if you execute ``gzexe /usr/bin/gdb'' it will create the following two files: -rwxr-xr-x 1 root root 1026675 Jun 7 13:53 /usr/bin/gdb -rwxr-xr-x 1 root root 2304524 May 30 13:02 /usr/bin/gdb~ /usr/bin/gdb~ is the original file and /usr/bin/gdb is the self-uncompressing executable file. You can remove /usr/bin/gdb~ once you are sure that /usr/bin/gdb works properly. This utility is most useful on systems with very small disks. OPTIONS
-d Decompress the given executables instead of compressing them. SEE ALSO
gzip(1), znew(1), zmore(1), zcmp(1), zforce(1) CAVEATS
The compressed executable is a shell script. This may create some security holes. In particular, the compressed executable relies on the PATH environment variable to find gzip and some standard utilities (basename, chmod, ln, mkdir, mktemp, rm, sleep, and tail). BUGS
gzexe attempts to retain the original file attributes on the compressed executable, but you may have to fix them manually in some cases, using chmod or chown. GZEXE(1)
All times are GMT -4. The time now is 08:26 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy