13.07.2015 Views

Reports & Queries - Source : www.pcsoft-windev-webdev.com

Reports & Queries - Source : www.pcsoft-windev-webdev.com

Reports & Queries - Source : www.pcsoft-windev-webdev.com

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

In this example, the click code of the "Customer" button is as follows:WinDev code:WinDev Mobile code:// Open the preview windowiPreview()// Print the RPT_CustomerReport reportiPrintReport(RPT_CustomerReport)// Select the printeriConfigure()// Print the RPT_CustomerReport reportiPrintReport(RPT_CustomerReport)WebDev example:The "RPT_CustomerReport" report is based on the "Customer.TXT" file. This text file containsthe characteristics of the customers. This file is accessible from the server.The "RPT_CustomerReport" report is displayed in a PDF file during a click on the "Customer"button.In this example, the click code of the "Customer" button is as follows :// Generates a unique file nameFichierPDF est une chaîne = fRepWeb() + "\" + ..."RPT_CustomerReport_" + ...DateSys() + TimeSys() + ".pdf"// Prints the report in a PDF fileiDestination(iPDF, PDFFile)// Prints the RPT_CustomerReport reportiPrintReport(RPT_CustomerReport)// Displays the report in PDF formatFileDisplay(PDFFile, "application/pdf")// Deletes the PDF filefDelete(PDFFile)12.9 Print functionsThe following functions can be used to easily print reports:FunctionsiInitReportQueryiNestedHeaderFooteriPreview / iDestinationiPrintReportEffectInitializes the query linked to the report (for a query with parameters)Prints (or not) the page headers and footers of the nested reportConfigures the destination of the printPrints a report created in the report editorSee the online help for more details.Note: These functions are only required to print reports. Other print functions can be used to perform specificprocesses. These functions are presented in “Functions of WLanguage”, page 144.Part 1: Report editor 129

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!