Switch to: V10V9V8V7V6V5

VReport Class: Printing Methods

VReport.PrintToDisk()

Declaration:

PrintToDisk( 
    inLocation       as FolderItem, 
    inPrintType      as EVReportPrintType,
    inStartPageIndex as UINT = 0,
    inEndPageIndex   as UINT = 0  )

Parameters:

  • inLocation - The location for the generated file.
  • inPrintType - Specifies the format of the generated report.
  • inStartPageIndex - The index of the first page to be printed (1..N). Zero to print all records of the report.
  • inEndPageIndex - The index of the last page to be printed (1..N).

Description:

Prints all pages or the specified range of pages of the report to the disk file at the given location.

You can specify the format of the produced file with the help of the inPrintType parameter. Valid values for this parameter are enumerated in the EVReportPrintType enum type. Usually you will use these values as kToPDF, kToHTML, kToPicture_JPG.

Example:

theReport.PrintToDisk( "report_1.html", EVReportPrintType.kToHTML )

VReport.PrintToBuffer()

Declaration:

PrintToBuffer( 
    inPrintType      as EVReportPrintType,
    inStartPageIndex as UINT = 0, 
    inEndPageIndex   as UINT = 0 ) as BinaryData

Parameters:

  • inPrintType - Specifies the format of generated report.
  • inStartPageIndex - the index of the first page to be printed (1..N). Zero to print all records of the report.
  • inEndPageIndex - the index of the last page to be printed (1..N).

Description:

Prints all pages or the specified range of pages of the report to the disk file at the given location. You can specify the format of the produced file through the inPrintType parameter. Valid values for this parameter are enumerated in the EVReportPrintType enum type. Usually you will use these values as kToPDF, kToHTML, kToPicture_JPG.

NOTE: For different programming languages BinaryData will be different types. For example for REALbasic or PHP this is String because it can keep binary data, for Obj-C this is NSData, and so on. See example(s) of work with Report class in your Valentina ADK for details.

Example:

dim report as BinaryData
 
report = theReport.PrintToBuffer( EVReportPrintType.kToPDF, 1, 10 )