Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Right printer, wrong width
Message
De
09/11/2021 09:38:09
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Allemagne
 
 
À
09/11/2021 09:01:54
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de rapports & Rapports
Divers
Thread ID:
01682606
Message ID:
01682670
Vues:
42
Hi Héctor

VFPA? Visual FoxPro Advanced. A nice men from abroad is fixing the odd old bugs out of VFP. He's a geek fixing it in Assembler. Runs stable, no threads known so far.
http://www.baiyujia.com/vfpadvanced/f_vfpa_about.asp
Downloadable on this very site.
For me mostly it fixes the DPI problem and runs a decent printer dialogue.

The Monitor. Yess, this is because VFP looks on the DPI settings on the (main) monitor. This is used to render the report. VFP scales it the wrong way - harm done. What and where exactly is misplaced I have no idea, it least it's related.

If you have problems with printer and reports, make sure to have turned off the Printer environment (in the Report menu).
There is a way to store restore printer settings for later use, in a way that let the user store it's setting without dealing with the Reportdesigner.
Anway, I had never problems with REPORT FORM .. PROMPT, and I do SET REPORTBEHAVIOR 90 as long as VFP9 is available.
Be carefull with REPORTBEHAVIOUR 90, check the output, it renders text a bit longer, results may be cutted off.

To set the printer in VFP9 with a halfway modern OS you need something like
 TRY
   IF VERSION(5)<1000;
     AND VAL(OS(3))*100+VAL(OS(4))>=600 THEN
*VFP 9 (I do not use anything below 9)
    lcPrinter = GETPRINTER()
    IF !EMPTY(m.lcPrinter) THEN
     SET PRINTER TO NAME (m.lcPrinter)
     =SYS(1037)

    ENDIF &&!EMPTY(m.lcPrinter)
 
   ELSE &&VERSION(5)><10 AND VAL(OS(3))*100+VAL(OS(4))>=600
*VFPA
    =SYS(1037)
 
   ENDIF &&VERSION(5)><10 AND VAL(OS(3))*100+VAL(OS(4))>=600
 
   llError = .F.
  CATCH TO loException WHEN m.loException.ERRORNO=125
 * no printer installed
   llError = .T.
 
  CATCH TO loException
 * other error
   RAISEEVENT(THIS,'ERROR',m.loException.ERRORNO,m.loException.PROCEDURE,m.loException.LINENO)
   llError = .T.
 
 ENDTRY
>Hi Lutz.
>
>I don't know what VFPA is...
>
>I only know a few weeks ago I used "SET REPORTBEHAVIOR 90" and I almost commit suicide.
>
>I fixed it with
>
>SET PRINTER TO GETPRINTER() before report and deleting "prompt" from the instruction REPORT FORM.
>
>Thank you anyway.
>
> Héctor
>
>PD. The monitor????
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord

Weeks of programming can save you hours of planning.

Off

There is no place like [::1]
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform