Ok I have 2 pages both are asp pages.
On the registration form i have a button that when clicked opens up a pop up window with a list of icons that can be chosen from a database (this part works perfectly). I have populated the textbox on this page from the database.
Now my users can choose one of the icons click submit next to it and .... this is where i'm having problems.
What this script is suppose to do is write the value from the text box on the icon page to the parentpage(regform) text box.
but i keep getting error saying that its not null or an object?
First page I have the following javascript
<script language="javascript">
function openMe(){
var x=window.open('show.asp', 'newWindow',
'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=300,height=500,left = 300,top = 50');
}
</script>
'with the following input buttons in the formitself
<INPUT type=button value="Open It" name=submit1 onClick="openMe();"><p><input type="text" name="theBox" size="20">
on the pop up window i have the following
<script language="javascript">
function setOther(){
window.opener.theForm.theBox.value=
document.myForm.thisBox.value;
}
</script>
<form method="POST" name="myForm">
<p>
<input type="text" name="thisBox" size="5" value="<%=FP_FieldVal(fp_rs,"IconID"%>"><input type="submit" value="Choose" name="B1" onClick="setOther()";></p>
</form>
what am i doing wrong?
any help would be appreciated
frustratedDancin
On the registration form i have a button that when clicked opens up a pop up window with a list of icons that can be chosen from a database (this part works perfectly). I have populated the textbox on this page from the database.
Now my users can choose one of the icons click submit next to it and .... this is where i'm having problems.
What this script is suppose to do is write the value from the text box on the icon page to the parentpage(regform) text box.
but i keep getting error saying that its not null or an object?
First page I have the following javascript
<script language="javascript">
function openMe(){
var x=window.open('show.asp', 'newWindow',
'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=300,height=500,left = 300,top = 50');
}
</script>
'with the following input buttons in the formitself
<INPUT type=button value="Open It" name=submit1 onClick="openMe();"><p><input type="text" name="theBox" size="20">
on the pop up window i have the following
<script language="javascript">
function setOther(){
window.opener.theForm.theBox.value=
document.myForm.thisBox.value;
}
</script>
<form method="POST" name="myForm">
<p>
<input type="text" name="thisBox" size="5" value="<%=FP_FieldVal(fp_rs,"IconID"%>"><input type="submit" value="Choose" name="B1" onClick="setOther()";></p>
</form>
what am i doing wrong?
any help would be appreciated
frustratedDancin