vcl-dxpscore-dot-tcustomdxcomponentprinter-dot-printpages-x28-dxpsglbl-dot-tdxpspageindexes-dxpscore-dot-tbasedxreportlink-x29.md
Prints specified report pages.
procedure PrintPages(const APageIndexes: TdxPSPageIndexes; AReportLink: TBasedxReportLink = nil);
| 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.
|
Call the PrintPages procedure to print specific report pages.
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;
TdxPSPageIndexes *APages = nullptr; // Stores the list of required report pages
// ...
SetLength(APages, 2); // Sets the dynamic array size
APages[0] = 1;
APages[1] = 4;
dxComponentPrinter1->PrintPages(APages); // Prints target pages
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;
TdxPSPageIndexes *APages = nullptr; // Stores the list of required report pages
// ...
SetLength(APages, 1); // Sets the dynamic array size
APages[0] = dxComponentPrinter1.CurrentLink.CurrentPage;
dxComponentPrinter1->PrintPages(APages); // Prints the current page
See Also
dxPSCore.dxPrintComponent Procedure
TCustomdxComponentPrinter.Print Procedure
TCustomdxComponentPrinter.PrintEx Procedure
TCustomdxComponentPrinter.PrintPagesEx Procedure
TCustomdxComponentPrinter Class