TIBCO Business Studio Forms will automatically create Add and
Delete buttons for the records in a grid pane if you enable those options on the grid pane’s custom properties sheet. But in some cases, you may wish to provide custom logic to be executed when a record is added or deleted. To do this, you will customize the
Add and
Delete buttons.
To view the sample for this task, import the advanced sample projects as described in Import the Forms Advanced Samples. The sample form and business object model for the task described in this section are contained in the
forms.samples.scripting sample project.
The form (CustomGridActions.form) is at the following location:
The directions here assume that you already have a form with a grid pane that is bound to an array of objects of type forms.samples.scripting.GridRecord. In the sample, the
GridRecord class is in the business object model
FormsSamplesScripting.bom at the following location:
To customize the Add and
Delete buttons for the grid pane, perform these steps:
The shared script actions and rules described here can be examined in the Properties view by clicking their names in the
Outline view of the sample project’s
CustomGridActions form: