Skip to main content

TCustomdxComponentPrinter.PrintPages(TdxPSPageIndexes,TBasedxReportLink) Method

Prints specified report pages.

Declaration

procedure PrintPages(const APageIndexes: TdxPSPageIndexes; AReportLink: TBasedxReportLink = nil);

Parameters

Name Type Description
APageIndexes TdxPSPageIndexes

The array of required report pages.

AReportLink TBasedxReportLink

Optional. The source report link.

If this parameter is omitted (the parameter value is nil in Delphi or nullptr in C++Builder), the procedure uses the current report link as the content source.

Remarks

Call the PrintPages procedure to print specific report pages.

Code Examples

The following code example prints two pages from the current report link:

var
  APages: TdxPSPageIndexes;  // Stores the list of required report pages
begin
  SetLength(APages, 2);  // Sets the dynamic array size
  APages[0] := 1;
  APages[1] := 4;
  dxComponentPrinter1.PrintPages(APages);  // Prints target pages
end;

The following code example prints the current page of the current report link:

var
  APages: TdxPSPageIndexes;  // Stores the list of required report pages
begin
  SetLength(APages, 1);  // Sets the dynamic array size
  APages[0] := dxComponentPrinter1.CurrentLink.CurrentPage;
  dxComponentPrinter1.PrintPages(APages);  // Prints the current page
end;
See Also