Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Printer wide-font problem
Message
From
25/03/2004 21:45:32
Alan Harris-Reid
Baseline Data Services
Devon, United Kingdom
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Title:
Printer wide-font problem
Miscellaneous
Thread ID:
00889837
Message ID:
00889837
Views:
56
I am outputting a (very old, hand-coded) report directly to a printer using ??? for print commands and @ SAY for text posisitioning. I want some lines to be output in double-width font. The code looks something like this...

SET DEVICE TO PRINT
SET PRINT TO
??? CHR(27)+'@' && reset printer (necessary, but can't work-out why)

??? CHR(27)+'W1' && set wide font on
@0,0 SAY "Double-width text"
??? CHR(27)+'W0' && set wide font off
@1,0 SAY "Back to normal width"
@2,0 SAY "Further text in normal width"

SET PRINT TO
SET DEVICE TO SCREEN

This doesn't work - all printed text is in normal width. However, I found some very old code and discovered that the following code-block replacement works...

@0,0 SAY "Double-width text"
??? CHR(27)+'W1'
@1,0 SAY "Back to normal width"
??? CHR(27)+'W0'
@2,0 SAY "Further text in normal width"

Can anyone explain what might be going on, and what is the neatest way around this problem? Ideally I want the double-width lines 'wrapped' between the wide-font on/off commands, but it seems that the ??? wide on/off is required *after* the @ SAY... line. This doesn't make sense to me.

Any help would be appreciated.

Alan
Next
Reply
Map
View

Click here to load this message in the networking platform