Print system problems

Post Reply
User avatar
cdmmaui
Posts: 653
Joined: Fri Oct 28, 2005 9:53 am
Location: The Woodlands - Dallas - Scottsdale - London
Contact:

Print system problems

Post by cdmmaui »

Since upgrading to 8.02 I have found that my printer settings no longer work - they worked perfect with the previous version. The oPrinter:SetSize() does not work and the print preview still does not work. I have tried to pull the old rpreview.prg but there are still many problems. I have many forms that require oPrinter:SetSize() and this has become a major problem for me. Do I need to purchase the 8.03 upgrade to correct these problems? If I need to upgrade then can someone provide the correct code to call PRINTER PREVIEW from a dialog box as I must have dialog box so the user may select the necessary criteria for the printout. Thank you in advance for your assistance.
*~*~*~*~*~*~*~*~*~*
Darrell Ortiz
CDM Software Solutions, Inc.
https://www.cdmsoft.com
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Darrell,

We have not modified the source code of PrnSetSize() in source\classes\printdc.c.

Please check it in 8.02 and in the previous version that you were using, and you may find that they are the same:

Code: Select all

CLIPPER PRNSETSIZE( PARAMS )
{
   LPDEVMODE  lpDevMode;

   PrinterInit();

   lpDevMode  = (LPDEVMODE) GlobalLock( pd.hDevMode );

   lpDevMode->dmFields      = lpDevMode->dmFields | DM_PAPERSIZE |
                              DM_PAPERLENGTH | DM_PAPERWIDTH;
   lpDevMode->dmPaperSize   = DMPAPER_USER;
   lpDevMode->dmPaperWidth  = _parnl( 1 );
   lpDevMode->dmPaperLength = _parnl( 2 );

   GlobalUnlock( pd.hDevMode );
}
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Darrell,

In order to get the previous Print Preview behavior all is needed is to remove MDICHILD clause from source\classes\rpreview.prg

Without it, it should work as usual (without creating a MDICHILD window).
regards, saludos

Antonio Linares
www.fivetechsoft.com
Post Reply