The table Web component allows you to construct a table with multiple
columns that consist of multiple Web components. These Web components can
be mapped to the input and output parameters of the program that are defined
in the Web Interaction wizard.
The table Web component can also be used
with a service program on the host to display a list of records from an IBM® i database.
See the Parameters tab section below for information about selecting
this option. See the related links at the bottom for further information about
accessing database records and using subfile APIs.
General tab (iwcl:WTable)
- Name
- Enter a unique identifier for the IBM i Web component. Do not use blanks or hyphens in a name. See Rules for IBM i Web component names and values.
- Initial state
- The Hidden attribute indicates that the Web component
is not visible on the page.
- Orientation
- Select the value to indicate the direction of the text and the alignment
of the Web component on the page. The possible values are Default, Right-to-left,
or Left-to-right.
- Default
- Specifies that the text direction and the alignment of the Web component
on the page are inherited from the containing element.
For example, if the
Web component is inserted in a form, and the form's orientation is specified
as Right-to-left, then the orientation for the Web
component is also Right-to-left.
The default
is Left-to-right.
- Right-to-left
- Specifies that the text direction is right-to-left, and that the Web component
is right-aligned on the page. This value overrides the inherited value.
Note: If
you use Right-to-left when Edit code or Edit
word formatting is specified for the component, the formatted
number will not be displayed properly. To display it properly, specify right
horizontal alignment in Text layout for the inline
style.
- Left-to-right
- Specifies that the text direction is left-to-right, and that the Web component
is left-aligned on the page. This value overrides the inherited value.
- Summary
- Enter the description to be displayed if the browser is not able to display
the table.
- See Text string substitution for IBM i Web component labels for
information about externalizing text strings for text substitution purposes.
- Selection mode
- The available options are None, Single,
and Multiple.
- None
- Indicates that no Select column appears in the
table and no check boxes or radio buttons are shown.
- Single
- Indicates that a Select column containing radio
buttons is shown in the table. The radio buttons allow you to select one of
the records. When you do so, the selected row in highlighted.
- Multiple
- Indicates that a Select column containing check
boxes is shown in the table. The check boxes allow you to select more that
one record. When you do so, the selected rows are highlighted.
- Formatting
- Use this area to define how formatting is to be applied to the data in
the Web component.
- Get locale-sensitive values from
- Indicates how the decimal symbol, currency symbol, thousands separator,
and data separator are applied.
- When you select host system values, the values
for the decimal symbol, the thousands separator, and the date separator are
retrieved from the host job. The value for the currency symbol is retrieved
from the host system value QCURSYM.
- When you select client locale values, the values
for the decimal symbol, the currency symbol, the thousands separator, and
the date separator are retrieved from the locale of the Web browser at run
time.
- When you select user defined values, the values
shown for the decimal symbol, the currency symbol, the thousands separator,
and the date separator can be changed. The default values for the decimal
symbol, the currency symbol, the thousands separator are retrieved from the
locale of the client system at design time. The default value for the date
separator is "/"
Parameters tab
- Get table data from an IBM i service
program
- Select this option if the table Web component is intended for use with
a service program on an IBM i host.
When selected, the remaining options on the page are available for selection
and input.
- Library
- Enter the name of the library containing the service program that the
table Web component interacts with.
- Object
- Enter the name of the compiled service program that the table Web component
interacts with.
- Service program behaviour
- Select the option to indicate how the records that are read from the database
should be displayed in the table.
- Writes a page at a time
- This is the default. It indicates that the service program clears the
user space at the PGUP and PGDN procedures.
The INIT, PGUP, and PGDN procedures
need to be coded in the service program. This option also indicates that the
footer section displays only the page up and page down buttons.
- Writes a page as requested
- Indicates that the service program will not clear the user space at each PGDN procedure.
This option requires that the INIT and PGDN procedures
be coded in the service program. The footer section displays only the page
up and page down buttons.
- Writes entire subfile
- Indicates that a footer section is displayed in the table for paging purposes.
Page up and page down buttons appear in this footer as well as paging information
in the form of page x of y, for example Page 5 of 10.
This option also indicates that regardless of the number of records that are
read into the user space for display in the table, those records represent
the entire set of records that will be displayed in the table. This option
also requires that the INIT procedure is coded in the service
program . The PGUP and PGDN procedures are
not required since they are not invoked in this case.
- Service program parameters
- The service program parameters defined here are passed to the INIT ,
PGUP, and PGDN procedures of the specified service program. The procedures
accept up to two parameters. The first is the name of the subfile, and the
second is a data structure that receives the parameters defined here. The
fields defined in the structure must match the parameters defined here.
- Add
- Click Add each time you want to enter data to define
the service program parameters.
- Name
- Enter a unique identifier for the service program parameter. Do not use
blanks or hyphens in the name. The parameter name should match a valid session
variable that contains the value of the parameter.
- Data type
- Click in the field to enable a menu button. Click the button to open a
list of available data types. Valid types are Character, Packed
decimal, and Zoned decimal.
- Length
- Enter the value for the length of the parameter.
- Decimal
- For Packed decimal or Zoned decimal data
type, enter the number of decimal positions.
- Remove
- Click Remove to delete the selected service program
parameter.
- Up
- Click Up to rearrange the order of the selected
service program parameter.
- Down
- Click Down to rearrange the order of the selected
service program parameter.
Features tab
- Show toolbar
- This option is selected by default and results in a toolbar area appearing
in the table. This option also enables the following selections for the toolbar
contents:
- Enable table rows to be collapsed and expanded
- An icon is placed on the toolbar that collapses or expands the rows in
the table.
- Enable sorting
- An icon appears on the toolbar that enables sorting of data contained
in up to three columns.
- Enable filtering
- An icon appears on the toolbar that enables the filtering out of rows
based on conditions specified by the user.
- Show filter row
- This option is available when Enable filtering is
selected, and it indicates which rows have been filtered out of the table.
- Show header
- This option is selected by default. When selected, a header row containing
column headings appears at the top of the table.
- Show footer
- This option is selected by default. When selected, a footer row appears
at the bottom of the table for the next page and previous page controls. This
option must be selected if paging is to be specified.
- Enable paging
- Select this option to permit paging in the table. This option adds page
up and page down icons to the footer area of the table. Initial
page and Rows per page options are enabled
when this option is selected.
- Initial page
- Specify which page of table, other than page one, that you want to display
initially.
- Rows per page
- Enter a number to specify the number of rows that are to appear on each
page of the table.
- Show gridlines
- This option is selected by default. When selected, borders for the rows
and columns are visible in the table.
Columns tab
- Add
- Click Add each time you want to enter data to define
the attributes for a column in the table.
- Name
- Enter a unique identifier for the table column. Do not use blanks or hyphens
in the name.
- Length
- Specify the length of the data in this table column.
- Heading text
- Indicates the text description that appears as the column heading in the
table.
- See Text string substitution for IBM i Web component labels for
information about externalizing text strings for text substitution purposes.
- Features
- Click in the field to enable a menu button. Click the button to open the Column
Features window. Use this window to specify if the column is visible,
if filtering and sorting can be applied to the column, and the orientation
of the Web components in the column.
- Type
- Click in the field to enable a menu button. Click the button to open a
list of the Web components that can be selected for the table column. The
Web components available for selection are:
- Properties
- Click in the field to enable a menu button. Click the button to open the Column
Properties window. Use this window to specify the properties for
the Web components chosen in Type.
- Header Style
- Click in the field to enable a menu button. Click the button to open the Column
Header Style window. Use this window to specify the style for the
column heading.
- Data Style
- Click in the field to enable a menu button. Click the button to open the Column
Data Style window. Use this window to specify the style for the
column data. The style that is specified here overrides the style that is
specified in the Styles tab. If no style is specified here, the style specified
in the Styles tab is used.
- Remove
- Click Remove to delete the selected data for the
table column.
- Up
- Click Up to rearrange the order of the selected
column in the table.
- Down
- Click Down to rearrange the order of the selected
column in the table.
Styles tab
The Styles tab contains inline style
options for the
IBM i Web
component. The inline styles specified here are applicable to the body of
the table Web component only.
- Inline Style
- Select the Fonts, Font styles, Background and Text
layout buttons to open the respective style definition windows.
Use each window to select the options that you want to apply to the IBM i Web
component.