I have Active-X component on HTML page with long-run method (Process) that fires callback to javascript.
activex.Process(
function (message) {
// alert(message); --> message box appears, everything ok
$("#panel").text(message); // panel doesn't refreshed!
}
}
<div id="panel" >
active-x messages should be here!
</div>
Callbacks fire ok (I can see messagebox’es) but panel doesn’t refreshed until Process method returns.
May I force panel to be refreshed or shall I fire callbacks from another thread?
Thank you in advance!
If you’re calling
activex.Process()from JavaScript, then the browser blocks until the JS function returns.Try to create a new thread in
Process()and return immediately. That should “unlock” your browser. IE’s JavaScript engine should properly synchronize the callback code when you invoke it from your new thread.