Applied Principles (Magic xpa 4.x)
Ways to implement common application requirements according to the principles above are described below.
Sometimes you want to set a task whose interface is determined by user settings. When this is the case, it is best to define different forms that offer various display sets and use the Main Display task property to switch between the required displays instead of defining the task form with all the available controls and controlling their visibility.
See the Magic xpa Reference Guide to learn more about the Main Display task property.
Make sure you select only the necessary variables for the task. Unused fields, including parameters or subtask variables that are not used in the task logic flow, add to the page load.
It is wise to differentiate between information that must be displayed on screen, which is data of immediate need, and information that can appear in a pop-up window on demand. This will assure maximum performance ability for complex tasks. An example of this is a line mode table that displays customer details. It is best to show just the most needed information of each customer and to have a pop-up window that displays all the additional information for each customer on demand.
Sample application:
|
The Customer Details option demonstrates the Data on Demand mechanism.
|
It is best when a line mode task does not handle data entry logic. You can do this by keeping the line mode view as read-only and using a pop-up window for data entry instead of updating the lines directly. In this way, scrolling through a line mode task does not require the excess re-computation and verification logic required for data entry tasks.
Choice controls should only be used in data entry pages.. There is no need to burden the page with the long list of values required for every choice control. Simply display the data.
When displaying one-to-one related records from two different tables, it is preferable to display the record of the second table using a Link operation instead of using a subform.
Similar to the concept of details on demand, the performance of a task is improved when detail lines are displayed in a pop-up window by clicking a push button or a link on demand instead of showing the details lines in a subform.
Sample application:
|
The Orders Entry II option demonstrates the lines-on-demand mechanism.
|