How do I prevent JQuery Accordion in Spotfire from resetting when IronPython scripts are triggered

I am using the JQuery Accordion in Spotfire to create an expanding and collapsing control panel for my dashboard:

 $( "#collapseheader" ).accordion({
   heightStyle: 'content'}

Inside of my accordion containers are property controls.  The user can expand different accordion containers to view different property controls.  When the property controls change value, they trigger IronPython scripts that perform calculations.  Every time that one of the IronPython scripts are triggered, regardless of which accordion container is expanded when the script is triggered, the accordion resets back to the default with the first container expanded and all of the others collapsed.  I need the accordion to keep its state after the IronPython script is triggered so that whichever container was expanded prior to the script triggering remains expanded after the script is triggered.

I would greatly appreciate any help that you can provide.

(1) Answer