Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
??? causes page eject-any way to prevent it?
Message
De
01/03/2002 21:09:29
 
 
À
01/03/2002 08:58:52
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de rapports & Rapports
Divers
Thread ID:
00626670
Message ID:
00627311
Vues:
10
>I found it in downloads.
>Tracy
>
>Update: I tried a test using dirprtclass, but I cannot find the CLSHeap.PRG. Where can I get it? It's not a part of dirprtclass.prg.

It's in the Files section - do a search on the word Heap, it's #986. You can also find it through my account profile, which lists my FAQ entries and downloadable files in the contributions section.

>Tracy
>
>Hi Ed,
>I read the description of your direct printer file, and it says that it will not work with @...SAY or ?/??
>Did I not misinterpret your description?

The class itself does not work with ? or @...SAY - there's a method that's the equivalent of ???, or as I suggested, send your print output to a file, and use the SpoolFile method to queue up the output as a raw print jpob without any GDI intervention.

>
>My problem is that I have some .frx reports, some .prgs that use @...SAY and some .prgs that use ??? to send text to the printer. All of them work EXCEPT the ones like EXAMPLE 2 below. I need to get example 2 working so I don't have to redo all of those .prgs IMMEDIATELY. They will be converted to reports later on, but there are too many to convert in my short deadline to get it working at least.
>
>Is it the 'SET PRINT ON' that is causing the page eject?
>
>EXAMPLE 1 WORKS CORRECTLY:
>
>*This example works fine.
>SET TALK OFF
>
>opt = ''
>port = GETPRINTER()
>
>
>SET PRINTER TO NAME (port)
>SET DEVICE TO PRINT
>
>??? OPT
>
>@10,10 SAY 'THIS IS A TEST 1'
>@11,10 SAY 'No Page is ejected before the line above which is correct'
>
>EJECT
>
>SET DEVICE TO SCREEN
>SET PRINTER TO
>
>SET TALK ON
>
>
>EXAMPLE 2 IS WRONG--IT EJECTS A BLANK PAGE BEFORE THE PRINTED PAGE
>
>*This example does NOT work-it ejects a blank sheet BEFORE printing everytime
>SET TALK OFF
>
>opt = ''
>port = GETPRINTER()
>
>
>SET PRINTER TO NAME (port)
>SET DEVICE TO PRINT
>
>SET CONSOLE OFF
>SET PRINTER ON
>
>??? OPT
>?
>? 'THIS IS A TEST 2'
>? 'TEST 2 Ejects a blank page FIRST-which is WRONG'
>?
>

You can get this effectively using the native methods of DIRPRTCLASS - you invoke a class method rather than using ???/??/?

>EJECT
>
>SET CONSOLE ON
>SET PRINTER OFF
>
>SET DEVICE TO SCREEN
>SET PRINTER TO
>
>SET TALK ON
>
>
>TRACY
>
>
>>Send the output to a file, and then use my Direct Printer Class in the Files section to directly spool the file without invoking the GDI.
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
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform