CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 HELP how to pass two value to a function onclick

Print topic Send  topic

Author Message
Aquananu
Posted: 09/24/2003, 6:47 AM

I am using a pop up page to choose from a list and return values of two fields from the popup page to the main page.

Only one value is being returned.

i have put setopener_list('{field1}, {field2}'); return false; in the onclick event of a link on a grid column.

code of The function setopener_list() is as below
<script language="JavaScript">
function SetOpener(field1, field2)
{
window.opener.document.record1.fielda.value = field1;
window.opener.document.record1.fieldb.value = field2;
window.opener.focus();
window.close();
}
</script>
{
Only value of first field1 is being returned to fielda, whereas field2 is not being returned, the variable fieldb shows 'undefined'.

how can we have a reference to the value directly i.e. document.lookupgridname.columnname

this gives an error that the var is not deifned or is null.

Please help
aQuananu
Posted: 09/24/2003, 7:19 AM

sorry for th trble

i found the sol

setopener_list('{field1}', '{field2}'); return false; instead as i had listed above

ensure that the field2 has been defined before you set the onclick function of the link.

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.