Quantcast
Channel: WinDev Forum
Viewing all articles
Browse latest Browse all 1914

[WD21] Storing and printing a PDF document (2 replies)

$
0
0
Hi guys,

I have a report (an invoice) that I want to store to disk as a PDF document and I also want to give the user the option to print it directly to the printer. I don't mind if the preview window pops-up or not, but how is this done without re-running with iPrintReport function? I assumed it would be easy - but do I really need to re-run iPrintReport with a different set of iDestination, iParameter functions??

I've come up with the following code to generate the PDF invoice, give it a filename and then store it to disk:

	iDestination(iPDF,gsDocuments + sTempFilename)
	iParameterPDF("","",iProtectionSelection+iProtectionModification)
	iPrintReport(RPT_ContractorInvoice,InvoiceHeader.ID)

...but how to print the PDF afterwards? Can't use iPrintPDF because that's not availoable to WD :sneg:

Viewing all articles
Browse latest Browse all 1914

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>