<html>
<head>
<script language="JavaScript">
<!--
function getName(){
alert("The length of this select box is " + document.myForm.mySelect.length);
}
-->
</script>
</head>
<body>
<form name="myForm">
<select name="mySelect">
<option value=A>AA</option>
<option value=B>BB</option>
<option value=C>CC</option>
<option value=D>DD</option>
</select>
<input type=BUTTON value="Get Name" name="myButton" onClick='getName()'>
</form>
</body>
</html>
|