function showWait() { var waitbg = document.createElement("div"); waitbg.style.position = "fixed"; waitbg.style.left = "0px"; waitbg.style.top = "0px"; waitbg.style.height = "100%"; waitbg.style.width = "100%"; waitbg.style.background = "black"; waitbg.id = "waitBg"; if (((navigator.userAgent.toLowerCase().indexOf("msie") != -1) && (navigator.userAgent.toLowerCase().indexOf("opera") == -1))) { waitbg.style.filter = 'alpha(opacity=30)'; } else // for mozilla { waitbg.style.opacity = 0.3; } document.body.appendChild(waitbg); var waitDiv = document.createElement("div"); waitDiv.id = "waitDiv"; waitDiv.style.position = "fixed"; waitDiv.style.width = "200px"; waitDiv.style.height = "150px"; var x = ((document.body.clientWidth/2) < 250)?(0):((document.body.clientWidth/2)-250); var y = ((document.body.clientHeight/2) < 50)?(0):((document.body.clientHeight/2)-50); waitDiv.style.left = x + "px"; waitDiv.style.top = y + "px"; waitDiv.style.background = "#dddddd"; waitDiv.style.border = "1px solid black"; waitDiv.style.color = "black"; waitDiv.style.font = "bold 18px Tahoma"; waitDiv.style.paddingTop = "40px"; waitDiv.style.textAlign = "center"; waitDiv.innerHTML = "Please Wait...

"; document.body.appendChild(waitDiv); } function hideWait() { document.body.removeChild(document.getElementById('waitDiv')); document.body.removeChild(document.getElementById('waitBg')); }