execute javascript method after method excution complete ?
Posted
by James123
on Stack Overflow
See other posts from Stack Overflow
or by James123
Published on 2010-05-13T00:11:17Z
Indexed on
2010/05/13
0:14 UTC
Read the original article
Hit count: 291
I want execute below callback()
method after completion of process document.getElementById('btnDownload').click();
method. click()
is the code behind method. That means, I mean after complete process of click()
then excute callback()
method.
Because my modelpop is not hiding in code behind. So I want hide in javascript method.
function LoadPopup() {
// find the popup behavior
this._popup = $find('mdlPopup');
// show the popup
this._popup.show();
// synchronously run the server side validation ...
document.getElementById('btnDownload').click();
callback();
}
function callback() {
this._popup = $find('mdlPopup');
// hide the popup
this._popup.hide();
alert("hi");
}
© Stack Overflow or respective owner