FieldValue Binding Properties

Go to:

Tools, Properties..., Bindings tab

The Bindings tab designates from where the data is retrieved or saved.  The selection criteria of the control’s associated Record control or Table control are used.  This option allows you to select a database field based on the surrounding Record tag properties you previously specified.  You do not need to specify the source of the record repeatedly for each of the field values contained in the record.

Specify the individual database fields to display for each control on the Bindings tab in the Properties dialog.

This is common for FieldValue tags enclosed within a surrounding Record or Table tag where the objective is to display a related set of fields coming from a single selected record.  In this case, the Record or Table tag specifies the record that is selected and the FieldValue controls display the individual fields.

<GEN:Record Name=”Customer”>
            <td><GEN:FieldValue Name="FirstName"/></td>
            <td><GEN:FieldValue Name="LastName"/></td>
            <td><GEN:FieldValue Name="Address"/></td>
            <td><GEN:FieldValue Name="City"/></td>
            <td><GEN:FieldValue Name="State"/></td>
            <td><GEN:FieldValue Name="ZipCode"/></td>
            <td><GEN:FieldValue Name="Country"/></td>
</GEN:Record>

The record retrieved by the parent tag – a Record tag or Table tag – determines the data displayed for the enclosed FieldValue tags.

Code generation tags can both display data as well as input data, depending on their property settings.  Either way, there is no difference in how the code generation tags are used.

In this example, the customer information is sourced from a single record in the Customers table and displayed on the web page.  The Record tag is bound to the Customers table.  The individual FieldValue tags are set to source their data from specific fields in the Customers table.

In this example, the name, address, and other contact information is collected from the web page and inserted into the Customers table in the database.  The Record code generation tag is bound to the Customers table.  The individual FieldValue tags would typically have their query bound to “Add new record”.

This option also applies to the FieldValue tag if it is enclosed within a row of a table being displayed.  This is meaningful in the context of a FieldValue tag in a table in which the "current row" in the table is bound to a particular record.  As the table iterates over each record in the result set, each corresponding record is fetched and the appropriate field values retrieved and displayed.

Furthermore, you can add additional criteria to further filter the previously defined query or the records from the table.

Options

Description

Table, view or query

Specifies the database table containing the field to be displayed.

Field

Specifies the field to be displayed.

Enable View State

Indicates that View State is saved for the field.  Disabling the View State will improve run-time performance but no data will be retained when the application user moves from page to page.

See Also

FieldValue Tag

FieldValue Control Type Properties

FieldValue Display Format Properties

Label and Literal Control Options

File Upload and File Download Control Options

List Control Options

Text Box Control Options

FieldValue Initial Value Properties

FieldValue Binding Properties

FieldValue Pass-Through Attributes