Previous Page | Next Page

Universal Printing

Using FTP with Universal Printing


Overview of Using FTP with Universal Printing

SAS enables you to use FTP to send universal printing output to a printer or to a file that is on another server, another machine, or another operating system. When you use FTP, such as in the FILENAME statements in the following examples, you have to specify the recfm=s parameter.


Sending Output to a Printer

The following code example sends PostScript output to the printer that you specify with the host option of the FILENAME statement. The host option specifies the IP address that your printer is connected to, and the user option specifies your user ID. The pass option specifies your password. You can replace pass with the prompt option if you prefer to be prompted for your password at run time.

The following example produces output that has a border and contains the text, "Example Output with recfm=s."

filename grafout ftp ' ' 
   host="IP address" 
   user="username" 
   recfm=s
   pass="user password"; 
                                                                 
options printerpath=('PostScript Level 2' grafout); 
goptions reset=all dev=sasprtc gsfname=grafout gsfmode=replace; 
proc gslide border; 
    title 'Example Output with recfm=s';
run; 
quit; 
filename grafout clear;


Sending Output to a File

The following code example sends PostScript output to a file in a UFS directory on a remote system that you specify with the host option of the FILENAME statement. The host option specifies the name of the server that your UFS directory is located on, and the user option specifies your user ID. The pass option specifies your password. You can replace pass with the prompt option if you prefer to be prompted for your password at run time.

The following example produces output that has a border and contains the text, "Example Output with recfm=s."

filename grafout ftp '~username/filename.ps' 
   host="hostname" 
   user="username" 
   recfm=s
   pass="user password"; 
                                                                     
options printerpath=('PostScript Level 2' grafout);  
goptions reset=all dev=sasprtc gsfname=grafout gsfmode=replace; 
proc gslide border; 
   title 'Example Output with recfm=s';
run;  
quit; 
filename grafout clear;

Previous Page | Next Page | Top of Page