function ShowErrorMessage(message, title, RedirectURL, PageRebind) {
///<summary>
///function used to Show Messages
///</summary>
if (!title)
title = errorTitle;
$(".error").html("");
$(".error").html(message);
if (RedirectURL) {
$(".error").dialog({
resizable: false,
title: title,
buttons: {
OK: function (e) {
window.location = RedirectURL;
}
},
beforeClose: function (event, ui) { window.location = RedirectURL; },
modal: true,
open: function (event, ui) {
$(this).parent().appendTo("#popupHolder");
}
});
}
else {
$(".error").dialog({
resizable: false,
title: title,
modal: true,
open: function (event, ui) {
$(this).parent().appendTo("#popupHolder");
},
close: function (event) {
if (typeof AfterMessageClose == "function" && PageRebind == true) {
AfterMessageClose();
}
}
});
}
return false;
}
///<summary>
///function used to Show Messages
///</summary>
if (!title)
title = errorTitle;
$(".error").html("");
$(".error").html(message);
if (RedirectURL) {
$(".error").dialog({
resizable: false,
title: title,
buttons: {
OK: function (e) {
window.location = RedirectURL;
}
},
beforeClose: function (event, ui) { window.location = RedirectURL; },
modal: true,
open: function (event, ui) {
$(this).parent().appendTo("#popupHolder");
}
});
}
else {
$(".error").dialog({
resizable: false,
title: title,
modal: true,
open: function (event, ui) {
$(this).parent().appendTo("#popupHolder");
},
close: function (event) {
if (typeof AfterMessageClose == "function" && PageRebind == true) {
AfterMessageClose();
}
}
});
}
return false;
}
No comments:
Post a Comment