Click to See Complete Forum and Search --> : drop down menu and deleting a child?


pelegk1
01-22-2003, 04:20 AM
i am trying to deleter child i in a drop down menu
the line marked in (***)! it wont let me!why?what can i do so i can delete a child and get a new drop down withought child i?
this is the code:
<html>
<head>
<title>Untitled</title>
</head>
<script languge="javascript">
function deleteItem(obj){

with(obj){
alert(obj);
alert (obj.selectedIndex);
removeChild(obj.options[obj.selectdIndex]) //***
}
}
</script>
<body>
<form>
<select id="ddb1" >
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
</select>
<INPUT type="button" value="Delete Value" id=button1 name=button1 onclick ="
deleteItem(ddb1)">
</form>
</body>
</html>

thanks in advance
Peleg

pelegk1
01-22-2003, 08:32 AM
nope its not working :(

pelegk1
01-23-2003, 03:33 AM
but what the diffreence!
i dont see any difrence in the code and it still works?why?
by the way : whee i can find a dtat about all the objects and there properties?
thnaks agaiin
peleg