Choosing a builder that adds and controls page elementsAdded by IBM on August 31, 2010 | Version 1 (Original)
|Many builders help you add and control page elements.
Many builders help you add and control page elements.
Table 1. Builders to add and control page elements
|Task||Builder you should use|
|Show or hide a page element based upon certain conditions or based upon a value. |
For example, you have a select list that allows a user to select a product. When a product is selected, all of the part numbers that make up that product are displayed in a table below the select list. When no product is selected, the table does not appear.
|Use the Visibility Setter builder to control what is displayed in your application. When you add a Visibility Setter builder to your model, there are several ways you can control the visibility of the user interface element the Visibility Setter is attached to. You can:
In the example described in the associated task, the table is being hidden by a visibility setter. If the value in a variable is blank, then the table is hidden. When the variable contains a value, the table will be displayed.
- Hide a control always
- Hide a control based on a value
- Hide a control based on the comparison of two values
|You want to change an HTML attribute, but the builder you are using does not allow me to modify or add an attribute.||The Attribute Setter builder modifies existing elements on a page by replacing or adding to any HTML attribute values that those elements support. Use the Attribute Setter to add or modify attribute values not set by the builders in your model. You can use this builder to change the font, size, border, or any other supported attribute for a control.|
|Include the same page in several of my applications.|
Include a page generated by a builder onto an existing page. For example, when a customer is selected from a select list, to display a table below the select list.
Insert the display of a page in another model into a page in my primary model.
|Use the Inserted Page builder to insert the contents of a Page in the same model into a named location on a selected page (or pages). For example, you might want to insert a page created by View & Form onto an imported page.|
Use the Model Container builder to visually insert another model into a page. The other model can have its own page-to-page navigation without affecting the outer (container) model.
|Display some read-only text on a page.||The Text builder displays some text from a Variable or any other data source at a specified page location.|
|Use an existing tag library in a model.||The JSP Tag builder automates the process of using Java Server Page tags from a tag library. After you select a tag library descriptor file in the builder’s editor, you can quickly select a JSP tag to use on the page. After a tag is selected, the builder displays the tag's attributes, so you can easily specify the inputs.|
Parent topic: Choosing builders for common tasks: wpf7