|
 TS-497
CREATING A GRAPHICS STREAM FILE (GSF) ON THE MAINFRAME
SUITABLE FOR DOWNLOADING TO A PC
Question:
I have a Hewlett-Packard LaserJet printer attached to my PC, and I want
to produce IBM mainframe SAS/GRAPH output on my printer. How can I
create a graphics stream file (GSF) on the mainframe which I can
download to my PC and then send to my HP LaserJet or another ASCII
printer?
Answer:
To produce IBM mainframe SAS/GRAPH output on an ASCII printer attached
to your PC, follow these steps:
- Create a graphics stream file (GSF) on the mainframe.
Use the following SAS/GRAPH program as a guideline when creating
a graphics stream file on the mainframe:
filename gsasfile 'host-file-name' lrecl=132 recfm=vb;
goptions device = driver_name
gaccess = gsasfile
gprotocol = sasgpasc
gsflen = 128
gsfmode = replace;
* Test graph follows;
title 'SAS/GRAPH Test';
proc gslide;
run; quit;
* End test graph;
filename gsasfile clear;
If you are using a SAS/GRAPH PostScript driver for the
driver_name parameter and are running on the MVS operating
system, add
trantab=gtabcms to your GOPTIONS statement.
- Download the GSF to your PC as a binary file.
Once you have created the GSF on the mainframe, download the
GSF to your PC as a binary file. Downloading the GSF as a
binary file means that no EBCDIC-to-ASCII translation is
performed during the download and that no carriage return
or line feed characters are added to the GSF.
- Send the GSF to your printer.
Once the GSF has been successfully downloaded to your PC, use the
DOS COPY command to send the GSF to your printer:
COPY /B filename.ext port
The /B indicates to the DOS COPY command that the file to be
printed is a binary file and should be copied to the appropriate
communications port "as is".
For example, if the GSF on the PC is named SASGRAF.GSF and
your printer is attached to LPT1, issue the following COPY
command:
COPY /B SASGRAF.GSF LPT1:
If you are sending the GSF to a local LPT port, you may need
to set an "infinite retry" on the port first by specifying:
MODE LPT1:,,P
In certain situations, failure to issue the MODE command may
result in incomplete graphs or may result in error messages
from the COPY command.
These instructions can be used when producing mainframe SAS/GRAPH
output on any ASCII hardcopy graphics device attached to any
ASCII-based operating system. As long as you do either a binary
download or a binary transfer to your ASCII-based operating system,
you can successfully produce mainframe graphics output on any ASCII
graphics device which SAS/GRAPH supports.
|