|Ring||A ring control is a numeric input that presents a set of choices associated with numeric values.|
|Enumerated type, or Enum||The enum control is an object that presents a set of choices associated with an enumerated data type. The enumerated data type consists of a set of named constants.|
|Radio Button Group||The radio button group control is an object that presents a set of mutually exclusive choices associated with an enumerated data type. The enumerated data type consists of a set of named constants.|
|Listbox||The listbox control is an object that presents a set of items. Users may select single or multiple items at run time.|
|Control||When to Use||Examples: E-Commerce Application|
Use a ring when you want to provide a list of choices that represent numeric values. The ring control is a numeric input that allows the user to choose from a list of meaningful, human-readable values instead of numeric values.
If the logic of your program prefers numeric values to string values, use a ring.
You want to present users with a list of product names, each of which corresponds to a unique product number. You can specify the products' numbers as their respective numeric values. You can then cross-reference those numeric values to find the prices of the items.
|Enum and Radio Button Group||
Use an enum or a radio button group when you want to provide a list of choices associated with an enumerated data type.
If you want your program to deal with a fixed set of constants instead of arbitrary numeric data, use an enum or radio button group.
In general, use a radio button group when you have less than five options for the user to select from. A radio button group can help the user quickly scan the options.
You want to present users with a list of shipping speed options for the item they want to order. The numeric values assigned to each of the options are automatically defined. You cannot edit the numeric values.
You can use the enumerated data type in the enum control to drive the logic of your program. For example, because the names of the choices are part of the data type, you can use them to populate the cases of a Case Structure. This ensures that only valid states are used in your program.
Use a listbox when you want to provide a list of items in which users can select items at run time.
You want to present users with a list of products in which they can select one or more items.
You can also allow users to select zero items by checking the Allow no selection checkbox. For example, you can allow users to deselect all items.
Unlike the strings listed in rings, enums, and radio button groups, the strings listed in a listbox have no numeric representation. Additionally, enums and radio button groups require these numeric values to be sequential, unsigned integer values, while rings allow for much more freedom in assigning a numeric value.