General information
Category:
Reports & Report designer
Hi, Nadaya,
I finally found a way out, below is the program part about that. I hope it could help other person who meet the same problem.
===========================================================================================================
LOCAL lnI,lcTMPFileName,lcRPTName,lnCopies
lnCopies=3 && The Copies ypu wanna print out
lcRPTName="Bill.FRX" &&The Report Name
*!*Initial The Tmp File with a Unique Name
lcTMPFileName=SubStr(Alltrim(Sys(2015)),5)+Right(SYS(3),3)++".PRN"
*!*Print the report redirecting to the Tmp file, if user choice the exit buttom in preview mode, the tmp file wouldn't be created
Report Form (lcRPTName) PreView Noconsole TO File (lcTMPFileName)
*!*IF Tmp file exsit means the user pressed the print buttom in preview mde, then the programm make n copies as you wish.
IF FILE(lcTMPFileName)
FOR lnI=1 TO lnCopies
Report Form (This.Parent.Reporter) Noconsole TO Printer
NEXT
DELETE FILE (lcTMPFileName)
ENDIF
===========================================================================================================
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only