jBASE Web Builder Tutorial
Intro Step 1 Step 2 Step 3 Step 4 Step 5 Step 6 Step 7

Dealing with multi-values

Up until now, the application has only dealt with Attributes 1 and 2, the Name and Address. There is no facility to maintain the contents of attributes 3 and 4, the Phone Description and Phone Number fields. These fields are intended to be added in pairs to describe the telephone numbers of the Employees.

Support for Multi Valued sets of data like this is dealt with by some other jBC routines which are built in to Web Builder.

Add a label in the cell beneath the Address field. Change the label's Caption to Phone Description. Add another Label in the Cell just to the right of the Phone Description field, and change the Caption property to Phone Number.

Beneath these two labels, add a text box. Change the Datafield property of the Phone Description Textbox to 3, and the same field on the Phone Number Textbox to 4. Change the Dependent field Property to 3 for the Phone number Textbox.

Add buttons where indicated in the screenshot with captions of X, > and +.

Click on the button with the "+" caption. Change the Button type to Submit, the Trigger type to Sub, and the Trigger option to "sysmvaddnew". Change the Trigger parameter to 3. Click on the Update button to apply the changes.

Click on the button with the ">" caption. Change the Button type to Submit, the Trigger type to Sub, and the Trigger option to "sysmvins". Change the dependant field property to 3. Click on the Update button to apply the changes.

Click on the button with the "X" caption. Change the Button type to Submit, the Trigger type to Sub, the Trigger option to "sysmvdel", and the Trigger parameter to "skip". Change the dependant field property to 3. Click on the Update button to apply the changes.

When the Page is previewed, the user can now add as many Phone Description and Number pairings as required by using the new fields and buttons.

 

Next step >>