Modifying existing report definition screens
After creating a new report or modifying an existing report and saving it with a new name, you may need to create a new report definition screen.
If an existing report definition screen has many of the fields required for selection, you can use it as a starting point for further modification. The following steps guide you through the process of modifying an existing report definition screen.
Important Note: Only report definition screens of a type RS or S that do not have a view name can be modified by non-Synergetic Management Systems users. Changes made to report definition screens that have a view name results in that screen being altered for all reports that share that screen! If you need to change a named report selection screen, Contact Synergetic Management Systems.
For this example we will use a Student Form List report which has been modified to include student asthma information. The report has been saved as STUFRMASTH. The existing Student Form List report definition screen needs to be modified so that students can be selected based on their different asthma categories. For this exercise, we shall also add the database fields of Given1 and Given2. The steps required are as follows:
- Select Module > System > User/Report Form Editor.
- Determine which report definition screen is the best to modify. Generally, this is the screen currently being used by the Crystal Report (STUFRM).
- Highlight the report STUFRM in the Report Selector.
- Click .
The following screen appears. - Enter the details for Report Code, Module, Description and Report Type.
- Click .
- Click on the confirmation window.
- Test that the newly entered details are correct by running the report:
• Select your new report and click . You return to the Report Selector window.
• Highlight your new form.
• Switch to the User Form Designer window.
• Click .
• You can see that this report definition screen is exactly the same as the STUFRM screen and has no options to select any asthma categories.
• Click . - To commence modifying this copied report definition screen, double click on the report resource STUFRMASTH in the Report Selector or highlight this report and click Load Source.
The User Form Designer window is displayed. - Click to gain an appreciation of what you are editing and to assess where you can insert the three new fields.
The Given1 and Given2 name fields are best placed underneath the Surname and Preferred name fields. The Asthma Category field can be placed in a GroupBox within the Optional Selections GroupBox in the right column. - Click to return to the User Form Designer window.
- Highlight Preferred in the User Form Designer grid.
- Click to create a new entry for Given1.
- Enter the values for Control & Property Definition and Editable Objects and SQL Syntax as shown in the screen capture below.
- Click to save the changes.
- Click to see how the user form has been altered.
- Highlight Given 1 in the User Form Designer grid.
- Click to create a new entry for Given2.
- Enter the values for Control & Property Definition and Editable Objects and SQL Syntax as seen in the screen capture below.
- Click to save the changes.
- Click again.
You will notice that the dimensions of the Optional Selections group box are not large enough to contain all of the fields now that you have added the two given name fields. - Highlight the second GroupBox in the User Form Designer grid and then modify the height property in the Additional Properties window until the GroupBox is large enough to contain all the fields.
- Add the Asthma Category field to the report definition screen.
You could insert it directly after the Leaving Date field but for this exercise, we can place it in its own Asthma Category group box inside the Optional Selections group box. Insert a group box by highlighting Leaving Date and clicking the button. - Enter the group box values for Control & Property Definition and Editable Objects and SQL Syntax as seen in the screen capture below.
- Click and then to see how the user form has been altered.
- Highlight the new group box and click to insert the Asthma Category field.
Because this database field corresponds to a lookup table, you can use a DBLookupComboBox or wwDBLookupCombo control. - Enter the group box values for Control & Property Definition and Editable Objects and SQL Syntax as seen in the screen capture below.
- Click .
- Click to test the finished report definition screen.