Custom Validation Example
Below is an example of a custom validation written to validation AP transaction lines coded to Fixed Asset G/L accounts to see if they meet the capitalization threshold.
To create a validation on the GL accounts on AP Trans. Entry or AP Unapproved Trans. Entry when the G/L account is a Fixed Asset account, you can use the following steps. It is a good idea to test this in a test database before impacting your live database.
1. In UD User Validation Create a new record for the Validation such as udAPFixedAssetThreshold.
2. In the SQL tab, enter the validation code from the text document here. Be sure that the GL Accounts listed are in the correct format and include the separators for your code format. Update the capitalization threshold dollar amount as required.
3. Save the validation and run the Compile button at the bottom of the form.
4. In AP Transaction Entry entry or AP Unapproved Transaction Entry form, press F3 on the Gross Amount field and go to the System Overrides tab. (You can also create a custom field just for validation, set the tab order and hide it from the form).
5. In the validation section, set the level to your preference such as Warning allow Save if you want to allow save.
6. Select the Custom validation from the lookup on the Procedure field.
7. Select the link button to link the form field to the input parameters for the validation, or in this example you can enter 205,240 in the Parameters field.
8. Click OK on the Field Properties form and it will reload the entry form.
9. Test your validation to ensure it works as you expect.