CodeCharge Studio
search Register Login  

Web Reports

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

YesSoftware Forums -> CodeCharge Studio -> Tips & Solutions

 Listbox onchange ajax form submit

Print topic Send  topic

Author Message
rcpilot

Posts: 2
Posted: 11/25/2008, 1:57 PM

After digging around a bit trying to figure out the root cause of why the Update Panel stops working right when you use the 'onchange' event to submit a form I found this solution.

http://www.robertnyman.com/2008/02/29/the-form-that-left/

Basically what it comes down to is that the javascript submit() function automatically overwrites everything the Update Panel uses for its 'onsubmit' event. If you're like me and you know that you'll need to call 'onsubmit' you can just straight up replace this (the code CCS writes when you add an onchange submit action):
document.forms["formname"].submit();

with this:
document.forms["formname"].onsubmit();

If you want the dual functionality of checking whether or not there's already an onsubmit event, then you'll want to read more in depth (in the comments really) within that link above.
View profile  Send private message

Add new topic Subscribe to topic   


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.