Option.selected PropertyNameOption.selected Property---whether the option is selectedAvailabilityNavigator 2.0, Internet Explorer 3.0 Synopsis
option.selected DescriptionThe selected property is a read/write Boolean value that specifies whether a Option object within a Select object is currently selected. You can use this property to test whether a given option is selected. You can also use it to select (by setting it to true) or deselect (by setting it to false) a given option. Note that when you select or deselect an option in this way the Select.onchange() event handler is not invoked. UsageTo determine the selected options in a Select object, you can loop through the Select.options[] array testing the selected property of each item. When multiple selections are not allowed (i.e., when the MULTIPLE attribute does not appear in the <SELECT> tag), however, it is much easier to simply check use the selectedIndex property of the Select object. |
|