|
|
|
|
- The steps for creating a RAD pattern
- Which pages must be created?
- The files to create
- Standard to follow
- The Vision Plus pages
- Overview
- Creating the Vision Plus page
- Creating the necessary elements in the form page
Creating the Vision pages of the WEBDEV RAD pattern
The steps for creating a RAD pattern Which pages must be created? The files to create Reminder: To build a RAD pattern used to create a full project, the following files are required: - A form for RADFileA.
- A form for RADFileB. A Vision Plus button (or a popup combo box) must allow you to select an element of RADFileA.
- A form for RADFileC. A Vision Plus button (or a popup combo box) must allow you to select an element of RADFileB.
- A table for RADFileA.
- A table for RADFileB.
- A table for RADFileC.
- A RADFileB/RADFileD relation page.
The main menu of the site can be included in the template associated with the pages. Standard to follow This help page presents the rules that apply when creating the pages of the RAD Pattern. These rules have been used to create the different patterns supplied with WEBDEV 16. These rules are recommendations. You can implement and use your own standard. Overview The Vision Plus pages are used to: - select an element of RADFileA from a form on RADFileB.
- select an element of RADFileB from a form on RADFileC.
Example: Selecting a customer from an order. The following elements allow you to use a vision plus page: - in the form page: a combo box and a button.
- a Vision Plus page. This page can be displayed by the button as a dialog box for example. This case is presented in this help page.
Creating the Vision Plus page The Vision Plus page contains: - a table.
- a Validate button (to validate the selection of the element) and a Cancel button.
To create a Vision Plus page: - Click in the quick access buttons.
- The creation window appears: click "Page" then "Page".
- In the wizard that starts, select "Blank" and validate.
- In the description window, enter the name of the page. This name must necessarily contain the name of the file displayed in the table (some examples: PAGE_Vision_RADFileA, PAGE_Visio_RADFileA, ...).
Remark: If you want to indicate the name of the current file to the user, use the name of the file (RADFileA for example) in a caption. The RADFileX term will be automatically replaced by the caption of the file described in the analysis. - Save the page.
- Create a Table control in the page: on the "Creation" tab, in the "Data" group, expand "Table" and select "Table".
- In the table creation wizard, specify the following characteristics:
- Select "Display the data from a file or from a query".
- Select the base file of the table (RADFileA for example).
- Keep the proposed item as well as the search item.
- Validate the name of the table.
- Position the Table control in the page and define its size.
- Create and position the different buttons of your page: Validate and Cancel.
- Case of the Validate button.
This button will be used to validate the selection in the table. The code of the Validate button is as follows:
// Close the page with True in return value PageCloseDialog(True)
Remark: the page is displayed as a dialog box (PageDisplayDialog). The True value can be returned to the calling page. - Case of Cancel button
This button is used to cancel the selection.
// Close the page with False in return value PageCloseDialog(False)
- Initialization code of page
// Position on the current record TableDisplay(TABLE_RADFileB, taCurrentFirst)
// Default return value MyPage..ReturnedValue = False
Creating the necessary elements in the form page The Vision Plus pages can be used from the following pages: - Form on RADFileB
- Form on RADFileC
A combo box and a button must be created in these pages. These elements can be stacked over the supercontrol corresponding to the form. To create the combo box: - On the "Creation" tab, in the "Usual controls" group, click "Combo box" and click the page.
- In the combo box creation wizard, select the following options:
- "Display the data coming from a file or from a query".
- Data file: RADFileA for a form on RADFileB, RADFileB for a form on RADFileC.
- Keep the default options. The stored item must be the identifier of the file.
- The combo box is linked to no item.
- the name of the control is "COMBO_IDRADFileX" (COMBO_ is the prefix defined in the code style: it is not required if no code style is used). For example, for the RADFileB form, the combo box will be named COMBO_IDRADFileA.
- Validate. The Combo Box control is created.
To create the button: - On the "Creation" tab, in the "Usual controls" group, click and click the page.
- In the control description window, specify the name of the button. This control has a name in the following format: "BTN_VISION_RADFileX" (BTN_ is the prefix defined in the code style: it is not required if no code style is used). For example, for the RADFileB form, the button will be named BTN_VISION_RADFileA.
- The click code of the button is as follows:
// Open the vision page of RADFileB IF PageDisplayDialog(PAGE_Vision_RADFileB) = True THEN // Refreshes the content of the RADFileB combo box ListDisplay(COMBO_IDRADFileB) // Assign and position the combo box COMBO_IDRADFileB = RADFileB.IDRADFileB END
This code is used to open a a dialog box-like page to select records.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|