Formatta's Form Autofill feature allows users to configure forms in Formatta E-Forms Manager so that they may be automatically loaded with information from a database. Using Autofill, a form connects remotely to Formatta E-Forms Manager, which in turn connects to a database, retrieves data, and populates fields of the form with it. This technology allows your forms to be dynamically populated with data from a database in your environment without ever having to connect directly to the data source. Instead, Formatta E-Forms Manager brokers the transaction between the form and the database using pre-configured settings that you can define and customize.
Setup of a form for Autofill requires three main steps, which include:
Configuring a Data Source for connecting to an external database using ODBC in Windows
Defining one or more Autofill Queries that will read information from the database in Formatta E-Forms Manager
Creating Autofill Handlers, which map query results to a form in your Formatta E-Forms Manager catalog
Once configured and enabled, an Autofill operation takes place using the sequence of events described below:
An Autofill Handler is invoked, either from a button or other event in a form on a user's desktop, or automatically when the form is requested for download from Formatta E-Forms Manager.
If the Autofill Handler definition specifies that authentication is required, the form user will be challenged for a user ID and password, which must be supplied before the operation can continue.
The Autofill Handler checks the Autofill Query assigned to it. If the query requires dynamic parameters from a form dialog window, Formatta E-Forms Manager sends a dialog back to the form to collect the required data from the form user.
Any other dynamic parameters needed by the query may be retrieved from form fields or from an HTTP query string used to download the form. The parameter values are put into the query in place of tokens set when the query was defined.
The Autofill Handler connects to an external database using the ODBC data source assigned to the handler.
The Autofill Handler runs the query and checks for results.
Any results are parsed and placed into fields of the form or into an outgoing pop-up list dialog, using the Query-to-Form mapping specified in the handler definition.
If the results are presented to the user in a pop-up list dialog, the user clicks on one of the options in the list, populating form fields according to the Query-to-Form mapping specified in the handler definition.
E-forms can utilize Form Autofill in two distinct ways, depending on the nature of the application, using the Action Types described below:
Action Type 1: On Download: Forms can be configured in Formatta E-Forms Manager to have fields pre-populated with data from a database upon download from the Formatta E-Forms Manager catalog. Data retrieved from the database can be applied to one or more standard fields in the form, or can be placed as options in a drop-down list box field. This type of Autofill requires no interaction from the form user, and makes data available in the form as soon as it is presented to the user.
Another On-Download option allows you to populate a form with data from a query run against the database using parameters specified in a published form's unique download URL. This enables you to provide forms pre-loaded with specific information while dynamically setting the parameters for data retrieval at download time.
Action Type 2: Remote Command: Forms can be configured with commands in Designer to provide Autofill for certain field sets (or the entire form) when specific events are triggered by the form user. Such events may include the clicking of an action button, updating a field, printing the form, etc. When a form event is triggered that has an Autofill Remote command associated with it, the form then connects to Formatta E-Forms Manager remotely, which in turn retrieves data from the database and populates the appropriate fields of the form. The user may optionally be presented with a means of choosing a particular data set retrieved prior to form field population.
Formatta E-Forms Manager Autofill can populate form fields in a variety of ways, using the Autofill Types described below.
Autofill Type 1: Direct-to-Form: This type of Autofill can be invoked upon form download or from a Remote command. With this type, data retrieved from an Autofill query is placed directly into specific fields on the form without prompting the user to choose from a list of data set options.
Autofill Type 2: Listbox Field: This Autofill type can be invoked upon form download or from a Remote command. It can be used to populate a drop-down list box field (combo box) on the form from the database. This allows the choices in dropdown lists to be populated dynamically as an alternative to having them built into the form design.
Autofill Type 3: Pop-up List: With this Autofill type, a query is run against the database, and any records found are presented to the form user in a summary format on a pop-up list window. This allows the form user to choose from a list of records found. When the user clicks on an item in the pop-up list, one or more fields in the form are automatically populated with data elements corresponding to the record selected.
Note: A pop-up list can only be used in a Form Autofill with a Remote Command action type.