I use to Javascript page use $.blockUI in a function and I want 3 second block this page. That's why I added to setTimeOut but this function called to Redirect function after blockUI. Don't working setTimeOut in this code or called Redirect function.
How can I do it?
$.blockUI({
message: "block message",
css: {
border: 'none',
padding: '15px'
}
});
setTimeout($.unblockUI, 3000);
URL.Redirect("RedirectURLfunctionName");
In your code it will not wait for
setTimeouttimeout will only be executed after all the code in a block has finished executing.onUnblockcallback is invoked when all the blocking elements have been removed