piPreviewZoom - cDRReport¶
Methods - Properties - Events
Type¶
Default¶
100
Arguments¶
None
Description¶
Sets/Gets the preview zoom factor of a report. The contents of the viewer will be zoomed in or out.
This property cannot be accessed before the report OCX object is initialized. This is usually done inside the OpenReport method.
The value can be one of:
| Value | Description |
|---|---|
25-500 |
Percentage of the original size |
-1 |
Zoom to page width |
-2 |
Zoom to full (whole) page |
DataFlex Framework usage¶
- Windows
- FlexTron (using Windows views)
Sample¶
Object oReport is a cDRReport
Set psReportName to 'MyReport.dr'
End_Object
Object oZoomForm is a Form
Set Label to 'Zoom %:'
End_Object
Object oRunReportButton is a Button
Set Label to 'Run Report'
Procedure OnClick
Integer iFactor
Send RunReport of oReport
Get piPreviewZoom of oReport to iFactor
Set Value of oZoomForm to iFactor
End_Procedure
End_Object
Object oChangeZoomButton is a Button
Set Label to 'Zoom to 150%'
Procedure OnClick
// Set preview zoom factor of the current report to 150%
Set piPreviewZoom of oReport to 150
End_Procedure
End_Object