padraigosca
06-01-2005, 04:36 PM
Hi,
I would not say that i am a fan of javascript but I do need to use it this time around and i've been looking at this too long so i cant figure it out.
What i have is a parent window that is being passed a value from the child window.. the child window is seaching a database and returning the value the user clicks on. So far so good..
Where i am having difficulty is when i pass the selected count variable to the function i dont know how to make the "X" be equal to the count value..
ie. if count = 2,
var txtVal = document.formPop.name2.value;
var txtVal1 =document.formPop.id2.value;
function SendInfo(count){
var txtVal = document.formPop.nameX.value;
var txtVal1 = document.formPop.idX.value;
window.opener.document.form.customer_name.value = txtVal
window.opener.document.form.customer_id.value = txtVal1
window.close();
}
I would not say that i am a fan of javascript but I do need to use it this time around and i've been looking at this too long so i cant figure it out.
What i have is a parent window that is being passed a value from the child window.. the child window is seaching a database and returning the value the user clicks on. So far so good..
Where i am having difficulty is when i pass the selected count variable to the function i dont know how to make the "X" be equal to the count value..
ie. if count = 2,
var txtVal = document.formPop.name2.value;
var txtVal1 =document.formPop.id2.value;
function SendInfo(count){
var txtVal = document.formPop.nameX.value;
var txtVal1 = document.formPop.idX.value;
window.opener.document.form.customer_name.value = txtVal
window.opener.document.form.customer_id.value = txtVal1
window.close();
}