Portlet Factory, Version 6.1.2
Formatted Text builder
Use the Formatted Text builder to format values for display on a page. The Formatted text builder produces uniform formatting of dates and numbers. A typical use case for this builder is when you want to display a value as currency or as a date. You can also opt to make the displayed value editable. In this case, the value is presented within a text input box from which you can retrieve data.
This builder uses Java's MessageFormat and SimpleDateFormat classes to convert user input to appropriate formats. This conversion occurs at runtime, and the following conversion formats are supported:
- Supported number formats include:
- Currency – $987,654.00
- Percentages – 98%
- Supported date input formats include:
- E MMM dd yyyy hh:mma – Thu Dec 13 1962 12:00AM
- MMM dd yyyy hh:mma – Dec 13 1962 12:00AM
- yyyy-MM-dd HH:mm:ss – 1962-12-13 12:00:00
- long – 48923332
- Supported Date Output formats include:
- E MMM dd yyyy hh:mma – Thu Dec 13 1962 12:00AM
- MMM dd yyyy hh:mma – Dec 13 1962 12:00AM
- yyyy-MM-dd HH:mm:ss – 1962-12-13 12:00:00
When working with dates, choose an input format. That format must be strictly adhered to when a date value is entered. If the date value is entered incorrectly, it will not be converted to the output format you have selected.
When working with percent, enter a decimal value to represent a percent less than 100%.
You can customize the input and output date formats to add more supported date formats.
Parent topic: Builder help
- About using the builder call editor
The builder call editor allows you to specify all the input values to a builder call.
- Locating control builder calls on pages
Each page location technique results in the generation of a Page Location string that determines on what pages, and where on those pages, the control builder calls are added.
- Formatted Text builder inputs
This topic describes the inputs for the Formatted Text builder.
- Overview: creating forms
You can create forms in IBM® WebSphere Portlet Factory applications in several ways.
- Formatting and validating form values
The Data Field Modifier builder, in conjunction with methods in a Java class, allows you to alter the format of field values as they are displayed or stored as data and provides for server-side validation of input values.
Library | Support |