This is a quick recipe for making a delayed IronPython call.

  1. Create a Text Area and edit the HTML
  2. Add a button for calling the script.  This will get an ID in the Edit HTML dialog, you'll use this later (buttonId)
  3. Create a JavaScript with no parameters

Set the code of the JavaScript to:

function() {
$('#e7f6c7579f2345a6b0edfde3353482aa').click(); // replace this with the buttonId, clicks the script and runs it
$('#calcRules').hide(); // Hides the image (for instance an icon or message that says "Running rules engine")
}, 1000); // timeout is set to run after 1 sec = 1000 ms

Your HTML will look something like this.  The 'calcRules' paragraph holds an image that gets hidden when the script executes.

<P>Run an iron python script.</P>
<P><SpotfireControl id="e7f6c7579f2345a6b0edfde3353482aa" /></P>
<p id='calcRules'>
<img src="33ba6a9b7b1440c384923c5ab86b7a17.png" style="border: 0; width: 100px; height: 100px;"/>
<P><SpotfireControl id="15300c24ad7f42368f45149bf7920f4e" /></P>