In this section: |
How to: |
When you dragged the fields from the data source into the form, you deselected the TITLE and USER fields so they do not appear in the form.
By not copying TITLE into the form, you prevent users from typing an arbitrary title in the field. We will give them the option to select Mr., Mrs., or Ms., using a radio button control. This prevents them from typing arbitrary titles.
The task of using radio buttons can be separated into three steps:
Your radio buttons should resemble the following image (you may need to adjust the size of your control to see all three of them).
You can move your cursor over the radio buttons at run time to see the tooltip.
If you wish, save your work and run your application again to see how it looks. Make sure to close the application before continuing the tutorial.
When you created AddFanStack using the Select Segment Fields dialog box (see How to Add Data Source Fields to a Form), you deselected the TITLE and USER fields. Since you deselected these fields, why are they showing up as columns in the data source stack?
These fields are showing up as columns in the data source stack because of the way App Studio Maintain Data defines data source stacks with the INFER command. When you use a field in the data source to define a column in a data source stack, App Studio Maintain Data defines columns based on the rest of the fields in that data source. If your data source is hierarchical, the rest of the fields in the segment and the key fields in any parent segment.
App Studio Maintain Data includes all of these fields in your data source stack so that when you update your data source from the data source stack, it knows the path to these fields.
These columns are called implied columns.
There is one field from the fannames data source that you have not placed on the form: the USER field. The user will not be entering this field. Instead, it will be generated by the application.