<font face="arial" size="2">Weird.&nbsp; Does it say which line?<br /><br />Also, did you increase the length of the options collection by 1 before adding the new option (in which case the index would be options.length - 1)?<br /><br />(hopefully this will come through sooner than my *last* message, which was delayed for hours and came through after you answered your own question)<br /><br /><br /></font><font face="Tahoma, Arial, Sans-Serif" size="2"><b>From</b>: "David Stoltz" <a href="mailto:Dstoltz@SHH.ORG">Dstoltz@SHH.ORG</a><br /></font><br /> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2">Actually - everything works now except ADDING an option to the select box (on the parent page)...the following fails:</font></span></div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2"></font></span>&nbsp;</div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2">window.opener.document.form1.mylist.options[window.opener.document.form1.mylist.length] = new Option('yourText', 'yourValue');</font></span></div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2"></font></span>&nbsp;</div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2">So does this:</font></span></div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2"></font></span>&nbsp;</div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2">var opt = new Option('text', 'value');<br />var sel = window.opener.document.form1.mylist;<br />sel.options[sel.options.length] = opt;<br />window.opener.document.form1.mylist.options[window.opener.document.form1.mylist.options.length] = opt;</font></span></div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2"></font></span>&nbsp;</div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2">Both give a "Server threw an exception" error...</font></span></div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2"></font></span>&nbsp;</div> <div dir="ltr" align="left"><span class="181033816"><font face="Arial" color="#0000ff" size="2">Any ideas?</font></span></div> <div>&nbsp;</div> <div><span class="181033816"><font face="Arial" color="#0000ff" size="2">Perhaps you cannot add an item to a select box on a parent window?</font></span></div><br /> <div class="OutlookMessageHeader" lang="en" dir="ltr" align="left"><font face="Tahoma" size="2"><b>From:</b> javascript-bounces@LaTech.edu <b>On Behalf Of </b>David Stoltz<br /></font></div> <div></div> <div dir="ltr" align="left"><span class="180090312"><font face="Arial" color="#0000ff" size="2">I get an error that says "<font face="Times New Roman" color="#000000" size="3">window.opener.document.form1.mylist.option" is null or is not an object</font></font></span></div> <div>&nbsp;</div> <div align="left"> <div align="left"><font face="Tahoma" size="2"><b>From:</b> javascript-bounces@LaTech.edu <b>On Behalf Of </b>Peter Brunone<br /></font></div></div> <div></div><font face="arial" size="2">Hi David,<br /><br />&nbsp;&nbsp;&nbsp;You should be able to use the same syntax, as long as you refer to it through the window.opener object...<br /><br />&nbsp;&nbsp;&nbsp;When someone tells me "it doesn't work", I automatically ask what is really going on.&nbsp; Are you seeing an error message -- and if so, what does it say -- or is something unexpected happening, or is nothing at all happening?<br /><br />Cheers,<br /><br />Peter<br /><br /></font><font face="Tahoma, Arial, Sans-Serif" size="2"><b>From</b>: "David Stoltz" <a href="mailto:Dstoltz@SHH.ORG">Dstoltz@SHH.ORG</a><br /></font><br />Hi All,<br /><br />I have a problem - I am popping up a child window, and I need to:<br /><br />1) Clear a select box on the parent of all it's options<br />2) Add new options to the select box on the parent window<br />3) Select (highlight) an option in the select box on the parent window<br /><br />Can anyone give me any code how I can do this from the CHILD window? I<br />am trying with this so far to select an option, with no luck:<br /><br />window.opener.document.form1.mylist.option[0].selected=true;<br /><br />Thanks for any help