Information générale
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
How to print a formset ??
Hi Foxpro Professionals
I know how to print a form !
I know how to print the complete application window
I do it like this:
PROCEDURE PrintForm
DECLARE INTEGER GetFocus IN WIN32API
do PrintWindow with GetFocus(),"Masken Druck"
RETURN
PROCEDURE PrintWindow
LPARAMETERS tnHWnd, tcJobName
LOCAL lcJobName && Print job name
LOCAL lnRetVal && Return value from API functions
DECLARE INTEGER PrintWindow IN DibApi32 ;
INTEGER HWnd, ;
INTEGER fPrintArea, ;
INTEGER fPrintOpt, ;
INTEGER wxScale, ;
INTEGER wyScale, ;
STRING @ szJobName
*!* Print entire window or just client area
#DEFINE PW_WINDOW 1
#DEFINE PW_CLIENT 2
*!* How to size the printed image
*!* PW_BESTFIT resizes to fill paper while retaining proportions
*!* PW_STRETCHTOPAGE resizes to completely fill paper, distorts proportions
*!* PR_SCALE scale print size
#DEFINE PW_BESTFIT 1
#DEFINE PW_STRETCHTOPAGE 2
#DEFINE PW_SCALE 3
*!* If you are not including FoxPro.H uncomment these lines
*!* #DEFINE MB_ICONEXCLAMATION 48
*!* #DEFINE MB_OK 0
lcJobName = tcJobName + CHR(0)
lnRetVal = PrintWindow( tnHWnd, PW_WINDOW, PW_BESTFIT, 0, 0, @lcJobName)
IF lnRetVal != 0
IF lnRetVal != 6 && 6 = User canceled printing
= MESSAGEBOX("Unable to print the window" + CRLF + ;
"PrintWindow API call returned " + STR(lnRetVal), ;
MB_ICONEXCLAMATION + MB_OK, ;
"ERROR MESSAGE TITLE")
ENDIF
ENDIF
RETURN
endproc
My problem:
I use a formset !
There are always 4 forms on the screen !
One controlform and three forms with graphs and i don't know how to print this formset ????
Any help welcomed.
Best regards
Albert
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement