The ArrayList object is a collection of items containing a single data value.
Items are added to the ArrayList with the Add() method.
The Below code creates a new ArrayList object named players and four items are added:
By default, an ArrayList object contains 16 entries. An ArrayList can be sized to its final size
with the TrimToSize() method:
An ArrayList can also be sorted alphabetically or numerically with the Sort() method:
To sort in reverse order, apply the Reverse() method after the Sort() method:
An ArrayList object may automatically generate the text and values to the following controls:
To bind data to a RadioButtonList control, first create a RadioButtonList control (without any
asp:ListItem elements) in an .htmlx page:
Then add the script that builds the list and binds the values in the list to the RadioButtonList
The DataSource property of the RadioButtonList control is set to the ArrayList and it defines the
data source of the RadioButtonList control. The DataBind() method of the RadioButtonList control
binds the data source with the RadioButtonList control.
Note: The data values are used as both the Text and Value properties for the control. To
add Values that are different from the Text, use either the Hashtable object or the SortedList
Your Query was successfully sent!