For this tutorial, add a table for the user to submit a
list of expenses.
-
In the Manage tab, open the Expense
Report application by clicking Edit.
The Outline view displays all the forms and pages within an
application. You can change the default names of forms and pages to
more specific names. You can also move between form pages by clicking
them in the Outline view.
-
In the Outline view, click the Expenses page.
The blank Expenses page is displayed.
-
Add a section to the Expenses page,
and extend it to span all columns.
-
Click the Edit Properties icon,
and title the section Itemized Expenses.
-
Click the Display title bar check
box so the title is displayed on the form.
-
Click OK.
-
Expand the Specialized section of
the Palette and add a Table to the form.
-
To set the table headers, click the “here” link in
the information window.
A new child page is created for
the table that stores the form items that are used as table column
headers. A grid with one column and one row is displayed.
-
Add the following form items to the Table page,
either vertically, or horizontally.
When the user enters
data into the table, a window opens and displays the column headings
as a list. If there are more column headings than space in the window,
scroll bars are displayed to the user. You must decide whether you
want users to scroll vertically, or horizontally, then build the column
headers in that direction. Whether you build the list in the child
page, the column headers are displayed horizontally in the table on
the form.
-
Expand the Common section of
the Palette.
-
Add a Date. Set the Hint to Date
the expense was incurred.
-
Add a Drop Down. Set the Title to Type.
Set the Hint to Type of expense.
Click the Edit Properties icon. Then click
the Edit button in the Options: section.
Enter the following options into the displayed value column, create
row with the Add option icon after each: Air
Travel, Car rental, Food, Hotel, Postage, Other
-
Add a Single Line Entry. Set
the Title to Description.
Set the Width to Medium in
the Properties window.
-
Add a Currency. Set the Title to Amount.
Set the Width to Short.
-
Make all form items in the Table required by clicking the
required box for each item.
-
In the Outline view, click the Expenses page
to continue building the form.
On the Expenses page
notice that the table headings are displayed horizontally.
-
Expand the table to cover both columns in the grid.
-
Click the Edit Properties icon,
and set the title of the table to Your Expenses.
-
Enter a Hint.
For example: Enter
each itemized expense in the table.
-
Click OK.
-
Save and preview the form.
The Preview icon
is located with the Save icon.
When the preview is displayed, click Next to
get to the Expenses page. In the validation error
message window, click Continue. The error is
displayed because you are leaving the first page of the form without
entering data into mandatory fields. The table is then displayed with
no entries. Click the Add a new entry icon
to add test information to the table. A window is displayed containing
the column headers displayed vertically, and they all fit in the window.
If the table headers were entered onto the Table page
horizontally, the user must scroll to see all table fields.
Close
the preview form to return to building the form.
-
Set a formula on the table so the total of the submitted
expenses is displayed in a separate Currency area.
This total is supplied to the reviewer on the Approval page
you create next. On the Expenses page, add
a Currency form item beneath the table.
-
Click the Edit Properties icon.
-
Change the Title to Total
Expense Amount.
-
Click the Formula tab.
-
From the Choose the function used to set
the value of this item: select Table Sum.
-
Click the Column entry field.
A window opens for you to select a form item. Expand the tree
until Amount is available.
-
Click OK to set the formula.
-
Add Page Navigation buttons to the
end of the form.
-
Save and preview the form. If you enter test data into
the table, the numbers that are entered in the Amount columns
are automatically added and displayed in the Total Expense
Amount.