This chapter contains the following topics:
Find/Browse forms are used to query business views (BVs) and to select records from BVs for operations.
These events can occur on the find/browse form during runtime:
Dialog is Initialized
Post Dialog is Initialized
Grid Record is Fetched
Write Grid Line-Before
Write Grid Line-After
Last Grid Record Has Been Fetched
Call is Alerting
XAPI Subscribe Event
This section discusses how runtime processes find/browse forms.
When a find/browse form is called, runtime initializes these items in this order:
Error handling process
Business view columns (BC)
Form controls (FC)
Event rules structures
This flowchart illustrates the tasks that runtime performs after initializing these objects to complete dialog initialization:
Grid data selection and sequencing occurs at the control level.
The system creates an internal structure that represents the data selection and data sequencing requirements specified by the user. The system then passes this to the database engine to perform the actual database select and sequencing. The data used for selection is based on values from filter fields and query-by-example (QBE) columns. The system holds the data until the data is retrieved.
The Find button is a standard button on find/browse forms that appears by default. When the user clicks it, runtime fires the Button Clicked event. If no errors exist in the filter fields, runtime performs data selection and sequencing for the grid. After reloading the grid with the fetched data, runtime fires the Post Button Clicked event.
The Select button is a standard button on find/browse forms that appears by default. When the user clicks it, runtime fires the Button Clicked event. If no errors occur, runtime writes the values from the selected row to the BC and fires the Post Button Clicked event. Then it fires the End Dialog event and initiates the dialog close process.
The Close button is a standard button on find/browse forms that appears by default. When the user clicks it, runtime fires the Button Clicked and Post Button Clicked events in immediate succession. If no errors occur, runtime attempts to close all of the modeless child forms, if any exist. If any of these child forms cannot be closed, the Close button process is terminated. Otherwise, runtime fires the End Dialog event and initiates the dialog close process.
Find/Browse can be closed either by the user (typically by clicking the Select or Close buttons) or by the system. After performing any control-level close processing that might need to occur, runtime closes the form. If the event has not already occurred, runtime fires the End Dialog event. Then it performs these tasks in this order:
Load form interconnect data from BC for database commit.
Persist saved queries and grid formats
Terminate error and thread handling.
Destroy the window.