Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Printing report to non-default printer
Message
From
21/06/2001 18:30:53
Larry Huisingh
Lockheed Martin Information Technology
Richland, Washington, United States
 
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00522107
Message ID:
00522202
Views:
11
Hector and Cindy,

Thanks for your comments. They made me take a second and third look at my code. I had used the following code to set the printer to a non-default printer where vcPrinterName contains a valid printer name

vcPrinterName = "NAME " + vcPrinterName
set printer to (vcPrinterName)

This was in error because I was trying to use expression evaluation on the string. It would probably have worked if I had used macro expansion via

set printer to &vcPrinterName

However, because I am trying to avoid macro expansion, I am now using the following

set printer to name (vcPrinterName)

Everything seems to be working as desired now as long as I clear out the TAG and TAG2 fields of my reports. Thanks for all your help.

Larry

>Larry,
>
>I think that the answer is in the SET PRINTER TO NAME \\ServerName\PrinterName command. I just tried printing a dummy report to a real printer and to a PDF file with the following commands and it did work:
>
>set printer to name \\hcorrea2\canon
>set printer to name \\hcorrea2\pdfdriver
>
Larry Huisingh
Lockheed Martin Information Technology
Richland WA USA
Previous
Reply
Map
View

Click here to load this message in the networking platform