Introduction
The Advanced Criteria tab allows advanced users to select the operator they want to use with a given criterion. By contrast, the Criteria tab always uses the operator associated with a given criterion at design time; users have no ability to change the operator.
Prerequisites
- The form you need to edit must already exist.
- Any picklist ID-value pairings you are going to use must exist in the code ID framework table and must be configured in the table columns.
|
Quick Steps |
| 1 |
Add the Advanced Criteria tab |
| 2 |
Open the tab properties and update them |
| 3 |
Update the table |
| 4 |
Add controls from the entity attributes |
| 5 |
Configure the controls |
| 6 |
Add controls from the toolbox |
| 7 |
Configure the controls |
| 8 |
Add constraints to the controls |
| 9 |
Save the form |
Detailed Steps
Step 1. Add the Advanced Criteria tab.
To add the Advanced Criteria tab, right click the Criteria section, click the More icon, and select Add Advance Criteria.
The available tabs are:
- Adv. Criteria: Allows searching with operators.
- Query: Allows the user to see the executed query.
These are all going to be restricted to certain users. The Query Criteria tab is usually for the developers to make sure the queries are executed, as desired.
Step 2. Open the tab properties and update them.
The important properties are:
- ID: Programmatic ID.
- Visible: Determines whether a user can see a control. By default, visible is set to true.
Here, the caption of Adv. Criteria has been updated.
Step 3. Update the table.
The controls go in the table, so its dimensions are important.
Tip: You can add/delete rows/columns with the right click menu. There is no icon for deleting rows/columns.
Step 4. Add controls from the entity attributes.
In the entity attributes, select the column that stores the value you want to use and drag and drop it to the advance criteria panel. Xelence creates a new row under the selected row and drops the control there, with a caption above the control. The controls are available for further configuration; if that’s not needed then they are ready for the user to search with.
You can’t simultaneously add columns of more than one control type.
The lookup form automatically uses a select * from form object table query as the main query. If you want other tables available, add or edit the query in the form details.
Usually adding controls from the entity attributes requires no further configuration, but there are exceptions (cascading drop downs, etc.)
Step 5. Configure the controls.
Xelence adds the entity attributes as default controls. You can change the default control if you want it to be different.
This example changes the controls for Created By and Designation.
Step 6. Add controls from the toolbox.
In the toolbox, select the control. Drag and drop the control to the desired location.
Step 7. Configure the controls.
If the control is a field, at minimum, enter its Query Field and Caption. The Query Field binds the control to the table column. The Caption names the field for the user.
If the control is a button, at minimum, enter its Action Type and Caption. The Action Type determines what the button does and the Caption names the button for the user.
Some control properties are based on the entity, such as queries.
Some control properties are based on the framework, such as picklist IDs.
Some control properties are based on the server methods.
Some control properties are depending on the developer’s whim, such as programmatic IDs or text.
Some control properties are dependent on other controls, such as a parent or related control.
The minimum configuration often makes the control ready for the user to search with. If not, you will need to configure properties further.
This example configures the Misc button, Postalcode field, Created By field, and Created Dates field. Open the Misc button properties.
Open the General section and enter the Action Type as Store User Defaults. Update the caption so the user knows what the button does.
Open the Icon Css section and update the caption.
Open the Postalcode properties.
Update the caption in the Caption section.
Open the Created By field properties.
Click the Data Source icon to change how the application populates the field. Currently, it uses a picklist.
Update the Data Source to Query. This query comes from the User entity and must exist there before it can be used here.
Open the leftmost Created Date properties.
Update the caption.
Repeat for the rightmost Created Date field to make it a Created Date To field.
Step 8. Add constraints to controls.
To add a constraint, right click the desired control and click Add Constraint.
Select the type. The types are:
- Required: The app will check the field value and enforce the constraint if it is null.
- Compare: The app will compare the field value to something and evaluate to true or false.
- MustBeEmpty: The app will check the field value and enforce the constraint if it not null or the default value.
Enter the rest of the details. The important properties are:
- Operator: Determines how the application will compare the field value to the Value property.
- Value: This is what the application will compare the field value to.
Check the Compare checkbox and enter the constraint details.
Step 9. Save the form.
Then, run the Preview. Xelence displays the form output. You can test your updated settings. When you have previewed your form, it should look something like this:
What are the improvements over S3 Version 6?
This process is identical.
Related Articles
Configure the Criteria Section
This post is part of the Lookup Form topic. Click here to open the Lookup Form Overview.
#Xelence
#Forms