Step 2. Create a Department Maintenance Web Page

In this step you will create a simple web page to fetch a record from the Department table.

In later steps you will add insert, update and delete logic to build a complete maintenance application.

1.  Create a New / Web Page / Blank web Page:

     Name: iiiMaintDepartment

     Description: Maintain Department Table

2.  Select the Layout ribbon and add a Table Layout with 2 rows, 1 column.

     Move the divider upwards. The top row will contain fields, the second row will contain push buttons.

3.  Locate the table xDepartments on the Repository tab. Expand its definition. Select fields xDepartmentCode and xDepartmentDescription and drag them onto the top row.

4.  Switch to the Source tab and locate the Define_Com for field xDepartmentCode. Change its visual component type to EditField:

Define_Com Class(#xDepartmentCode.EditField) Name(#xDepartmentCode) Displayposition(1) Left(20) Parent(#COM_OWNER) Tabposition(1)

5.  With both fields selected, using the Layout ribbon

a.  Change Alignment to Top Left and Flow to Down.

b.  Change margin Top to 10 and margin Left to 20.

6.  Drop a Push Button onto the second row.

a.  On the Layout ribbon, change Alignment to Top Left and Flow to Right.

b.  Give the button a margin Top of 20 and a margin Left of 20.

7.  With the button selected, select the Details tab.

a.  Change its Caption to Fetch

b.  Change its Name to Fetch

c.  Create a Click event for the button.

d.  Move the row divider upwards.

8.  Save your web page. The design should look like the following: