
//Set the page title according to the value set for the pgTitle hidden 
//value in the every page
function SetPageTitle()
{
	window.document.title=document.frm.pgTitle.value;
}


function WriteErrorMsg(c, m)
{
	document.getElementById("lblError"+ c).innerHTML = m;
	//c.focus;
	document.getElementById(c).focus();
		
}

function ClearErrorMsg(c)
{
	document.getElementById("lblError"+ c).innerHTML = "";
}



function init() {
				ns4 = (document.layers)? true:false
				if (ns4) {document.captureEvents(Event.MOUSEMOVE);}
				document.onmousemove = mouseMove;
			}
			function mouseMove(ev){
				ev           = ev || window.event;
				var mousePos = mouseCoords(ev);
				document.getElementById('divLoading').style.left=mousePos.x+10;
				document.getElementById('divLoading').style.top=mousePos.y+10;
			}
			function mouseCoords(ev){
				if(ev.pageX || ev.pageY){
					return {x:ev.pageX, y:ev.pageY};
				}
				return {
					x:ev.clientX + document.body.scrollLeft - document.body.clientLeft,
					y:ev.clientY + document.body.scrollTop  - document.body.clientTop
				};
			}