BookmarkSubscribeRSS Feed
FrankE
Fluorite | Level 6
Hey guys, I'm hoping you can help me out with this. I'm trying to send output directly to a networked printer with this code:

ods printer printer='Sequoia';
data test;
input @001 policy $10.;
cards;
1111111111
2222222222
;
run;
proc print data=test; run;
ods printer close;

I'm getting the message: ERROR: Unable to set printer path per request.
This is usually because the requested printer (Sequoia) is unknown.

and the output is printed on my default printer. What's strange is that the network printer is listed in "Printers" with exactly that name. Furthermore, if I change the above code to print to my default printer (Palm) it will give me the same "not found" message and print to Palm anyway because it's my default. So it seems SAS can see the printer just not with the name that is showing in the "printers" windows in Windows 2008 settings. Any way for me to have SAS tell me what printers it can see and what they're named?
3 REPLIES 3
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
The available ODS PRINTER documentation does not show a quoted string.

Scott Barry
SBBWorks, Inc.

Suggested Google advanced search argument, this topic / post:

ods printer set path site:sas.com

SAS ODS User's Guide, ODS PRINTER Statement:
http://support.sas.com/documentation/cdl/en/odsug/61723/HTML/default/a002217095.htm#a003068303
Cynthia_sas
SAS Super FREQ
Hi:
Here's an intriguing Tech Support note:
http://support.sas.com/kb/19/022.html which is about RTF and SAS EG - -but, it has this interesting bit of information:

This (error message) will most likely occur if the default printer name contains a
parenthesis. To circumvent the problem, either remove the parenthesis
from the printer name, or use HTML instead of RTF. Otherwise, if
removing parenthesis from the printer name is not acceptable, please
contact SAS Technical Support for a possible alternative solution.



Also, this Tech Support note has other examples of printers on Windows and other operating systems and at the bottom, tells how to find the printer names on your system:
http://support.sas.com/kb/24/185.html

If you continue to have issues, you might want to open a track with Tech Support.
cynthia

ps...FYI -- I had a network printer defined with an IP address in the name and when I tried to use ODS PRINTER using the network name, which did have parentheses, I got the same error message:
[pre]
8 ods printer printer='hp LaserJet 2300 series (192.168.1.132)';
ERROR: Unable to set printer path per request.
This is usually because the requested printer (hp LaserJet 2300 series
(192.168.1.132)) is unknown.
NOTE: Sending ODS PRINTER output to printer "hp LaserJet 2300 series (192.168.1.132)".
[/pre]
Of course, since that is my default printer, I didn't really need a printer= option in my code, but I wanted to see whether I could generate the same error message, and I could.
FrankE
Fluorite | Level 6
Thanks for your response. I looked at the directions you posted to finding the printers on my system and it was just as I thought. I used the exact method shown in the doc and still got the error message. I opened a ticket with SAS support to find out what's going on.

Thanks! Message was edited by: FrankE

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 1594 views
  • 0 likes
  • 3 in conversation