Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Set Printer To is not working?
Message
From
06/04/2000 17:46:56
 
 
To
06/04/2000 13:21:45
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00356384
Message ID:
00356567
Views:
13
>>I have users who need to print to a printer attached to lpt1 when printing out tags. I used the routine below to change the printer, then ran the label report. problem is it sends the report to the default printer instead of the lpt1 printer. When I checked the value of set("printer",1) it came out as "C:\VFE\CANNON BJC-50", but the value of lcprinter was "CANNON BJC-50". So why the path is being added I do not know. Can someone help me? I know I can use "PROMPT" but i'd rather just set it in code and go.
>>
>>Here is the code:
>>
>>aprinters(laprinters)
>>LNROW=ascan(LAPRINTERS,"LPT1:")/2
>>LCPRINTER=LAPRINTERS[LNROW,1]
>>SET PRINTER TO (LCPRINTER)
>>
>>LABE FORM mfgcut ALL NOCONSOLE TO PRINTER
>>
>>TTTIA!
>
>
Tony,
>set printer to name (lcPrinter)
>Cetin
Another possibility is that the LABEL carries the same embedded info about the printer as a report; take a look at the FAQ entry on stripping report info from an FRX as a guide.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Reply
Map
View

Click here to load this message in the networking platform