|
|
|
|
|
- Overview
- Manipulating PDF Reader controls programmatically
- Initializing a PDF Reader control
- Printing the content of a PDF Reader control
- PDF Reader control properties
Manipulating PDF Reader controls programmatically (prefix syntax)
PDF Reader controls can be manipulated programmatically. This help page explains how to programmatically manipulate PDF Reader controls. Manipulating PDF Reader controls programmatically Initializing a PDF Reader control To display a PDF file in a PDF Reader control, you can: - Define the initial document ("General" tab in the control description window).
- Assign the PDF file to the PDF Reader control. For example:
sNomFichier is string
sNomFichier = fSelect("", "Présentation.pdf", ...
"Sélection de fichiers PDF", ...
"Fichier Pdf (*.pdf)" + TAB + "*.pdf", "*.pdf", fselOpen)
IF sNomFichier ~="" THEN
RETURN
END
PDF_MonDocument = sNomFichier
If passwords are used: - If the file is password-protected, a window will appear to enter the password.
- It is not possible to open a protected PDF file.
- Use the <PDF Reader>.Open function. For example:
PDF_MonDocument.Ouvre("C:\Users\test\Documents\fichier.pdf")
IF ErrorOccurred() THEN
Error(ErrorInfo())
RETURN
END
Note: The <PDF Reader>.Open function allows you to program the file password.
Printing the content of a PDF Reader control To print the content of a PDF Reader control, all you have to do is use iPrintPDF. For example: iPrintPDF(PDF_MonLecteurPDF)
PDF Reader control properties The following properties are specific to PDF Reader controls. They are mainly used to handle the control characteristics:
| | DisplayMode | The DisplayMode property gets and changes: - the display mode in a Word Processing control,
- the display mode in a PDF Reader control
- the display mode in an HTML Editor control,
- the display mode in a Kanban control
| DisplayModeAutoWhenLoading | The DisplayModeAutoWhenLoading property is used to determine and change the display mode when loading a PDF document. | FilePath | The FilePath property gets: - the name of the xlsx file associated with a Spreadsheet control.
- the name of the file associated with an Image Editor control.
- the name of the PDF file associated with a PDF Reader control.
- the name of the DOCX file associated with a Word Processing control.
- the name of the wddiag file associated with a Diagram Editor control.
| NavigationPaneVisible | The NavigationPaneVisible property is used to display the thumbnail pane in the PDF Reader control. | NumberAccessiblePages | The NumberAccessiblePages property is used to get the number of pages currently loaded in a PDF Reader or Word Processing control. | NumberDisplayedPage | The NumberDisplayedPage property is used to identify and change the number of the page currently displayed in the PDF Reader or Word Processing control. | NumberPage | The NumberPage property is used to get: - the number of pages in a "multi-page" image file. This image is displayed in an Image control or in the background of a Chart control.
- the number of pages in a PDF file displayed in an Image control.
- the number of pages found in a PDF file displayed in a PDF Reader control.
- the number of pages found in a DOCX file displayed in a Word Processing control.
| UseMode | The UseMode property is used to determine or change how the PDF Reader control reacts to mouse input. The mouse is used to select text in the document or to move within the document pages. | Zoom | The Zoom property gets or sets the zoom value: - in an Image control.
- in a Map control.
- in an Organization Chart control.
- in a Table, TreeView Table, Pivot Table, Spreadsheet or List Box control.
- in a Word Processing control.
- in a PDF Reader control.
- in a Camera control.
- in a Diagram Editor control;
- in a window.
|
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|