Home | Sign in | English UK
This content comes from an automatic translation.
  • Overview
  • How to?
  • Creating the editable report
  • Characteristics of edit controls
  • Events associated with an edit control in a report
  • Entering in the report viewer
  • Input in a PDF file
  • Input in a report based on a PDF form
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Stored procedures
The report editor allows you to create reports that include edit controls. These reports can be generated in PDF format.
This gives you the ability to distribute reports (in PDF format if necessary) allowing the user to perform a direct input in the specified areas: administrative form (tax return, registration, ...).
The data can be printed or stored in a database (when the input is performed from the report viewer). Then, the report becomes an entry form.
The edit controls can be used on all types of reports. In most cases, the edit controls are used on the Form reports, using a PDF in report background for example.
How to?

Creating the editable report

To create an editable report:
  1. Create a report according to your requirements (see Creating a report for more details).
  2. Create the edit controls in the areas where the input will be performed: on the "Creation" pane, in the "Interactions" group, click "Edit".
  3. Save the report.
  4. During a print, the user will be able to directly enter data in the edit controls. The input is available:
    • in the report viewer.
    • in the reports printed in PDF format.

Characteristics of edit controls

When creating an edit control in a report, you have the ability to define:
  • the type of control (text, numeric, date, time),
  • the associated mask: the available masks are the ones supported by the PDF format. They are available for the numerics, the dates and the times.
  • the input size, which means the maximum number of characters allowed in the control. If this parameter is set to 0, there is no limit.
  • the horizontal alignment,
  • whether there is a border around the input area.
  • the initial value,
  • the style of caption and input area.
  • Multi-line edit control: if the users enter more lines than what is visible, the non-visible lines will not be printed. During the input, the edit controls manage a vertical scrollbar.
  • Style of input area: In this version, only the "Arial" font can be used.
  • The edit control is not linked to an item found a data file or in a query, nor to a variable. To display information coming form a data file, a query or a variable, the control must be assigned by programming.
  • The border of the input area cannot be configured (thickness, color, ...). You only have the ability to make it visible or invisible.
  • No currency type can be used (the Euro symbol is not supported).
  • It is not possible to make calculations between the different input fields.

Events associated with an edit control in a report

The following events are associated with an edit control in a report:
EventRuntime condition
InitializingRun when opening the report.
Before printingRun before printing a control.
EntryRun when the input cursor enters in the control.
ExitRun when moving from one control to another (TAB key, selecting another control with the mouse, etc.).
ModificationRun whenever the content of the control is modified (typing or erasing a character for example).
Entering in the report viewer
Windows When a report is displayed in the report viewer, the input fields are active.
In this case, the user will be able to enter the requested information and print the report in one of the available formats. A message is displayed in the report viewer to inform the user of the ability to enter information.
By default, the user can browse the edit control via the TAB key: the available controls are browsed from top to bottom and from left to right.
  • The events associated with edit controls are run when the controls are handled in the report viewer.
  • The data coming from the database can be displayed by programming. Simply link the report to a data file or to a query and assign the desired item to the edit control in the event "Before printing".
  • It is possible to save user modified data in the report viewer by programming.. Let's take a simple example, the modification of a record displayed in the report. In each edit control whose value must be modified, you must:
    • assign the entered value to the item,
    • modify the record.
    These actions are performed in the event "Exit from control".
    For example, to modify the customer name, the corresponding code is as follows:
    Customer.Name = EDT_Name
Input in a PDF file
When a report is printed in a PDF file, the edit controls are enabled. In this case, the user will be able to enter the content of the different edit controls and to print the PDF file with the entered values.
  • The edit controls are used to enter information in the PDF file. This information will be used during the print. If the end user owns a full version of Adobe Acrobat, the data entered can be saved in PDF format (Acrobat Reader cannot be used to save the PDF files).
  • The data coming from the database can be displayed by programming. To do so, link the report to a data file or to a query and assign the requested item to the edit control in the events "Initializing" or "Before printing" of the edit control.
Input in a report based on a PDF form
The edit controls are well suited to the "Form" reports. The "Form" reports are based on an image file or on a PDF file.
For a PDF form containing several pages, you have the ability to create a report displaying the different pages of the PDF file ("Print all the pages found in the PDF" option in the "Background" tab of the report description).
These pages are visible and they can be modified in the report editor: the edit controls can be positioned on any report page.
See Reports on form for more details.
Related Examples:
WD Reports Training (WINDEV): WD Reports
[ + ] This example presents the different methods for creating a report:

- prints based on different data sources (queries, variables, ...)
- prints based on controls (Table, Spreadsheet, PVT, ...)
- printing composite reports
- specific prints (portrait/landscape, report with watermark, report with bar code, ...)
Minimum version required
  • Version 12
This page is also available for…
Click [Add] to post a comment