var nv = navigator.appVersion.toLowerCase();
var nu=navigator.userAgent.toLowerCase();
var ie55 = ((nv.indexOf("msie 6.0")!=-1||nv.indexOf("msie 5.5")!=-1))? true : false;
var opera=(nu.indexOf("opera")!=-1)? true :false;
var opera5=(nu.indexOf("opera 5")!=-1)? true:false;
var opera6=(nu.indexOf("opera 6")!=-1)? true: false;
var opera7=(nu.indexOf("opera 7")!=-1||nu.indexOf("opera/7")!=-1)? true:false;
var scriptpath="js/progressbar/"
var _iF 

if( ie55)
{
//	alert("Internet Explorer 5")
	_iF=document.createElement("iframe");
//	if(location.protocol=="https:")
		_iF.src=scriptpath+"blank.html";
	_iF.id="iF";//+_mnuD ;
//	_iF.style.filter="Alpha(Opacity=0)";
	_iF.style.position="absolute" ;
	_iF.style.visibility="hidden"
	_iF.style.top="20px"
	_iF.style.left="20px"
	_iF.style.height="120px"
	_iF.style.width="220px"
	_iF.style.zIndex=99
	_iF.frameBorder=0
	document.body.appendChild(_iF)
}
//	alert(screen.height+"::" +screen.availHeight)
//Progress Bar Div
_divP = document.createElement("div");
_divP.id="progressbar"
_divP.align="center"
_divP.style.border="yellow 1px solid"
_divP.style.backgroundColor="#cfcfcf"
_divP.style.position="absolute"
_divP.style.visibility="hidden"
_divP.style.top="20px"
_divP.style.left="20px"
_divP.style.height="50px"
_divP.style.width="200px"
_divP.style.zIndex=99
_divP.frameBorder=0
_divP.innerHTML="<B>Please Wait...</B><br><img src='"+scriptpath+"progressbar.gif' id='progressbarimage'>"
document.body.appendChild(_divP)
//alert(_divP.innerHTML)
function setOnTop( objId )
{
	var obj
	var menuobj = document.getElementById(objId);
	menuobj.style.visibility='hidden';
//	alert("The menu is hidden now"+parseInt(menuobj.style.height))
	if( ie55)
	{
		obj = document.getElementById('iF');
		obj.style.top=(screen.availHeight-parseInt(menuobj.style.height))/2
		obj.style.left=(screen.availWidth-parseInt(menuobj.style.width))/2
		obj.style.height=menuobj.style.height
		obj.style.width=menuobj.style.width
		menuobj.style.top = obj.style.top
		menuobj.style.left = obj.style.left		
		obj.style.visibility='visible';
	}
	else
	{
		menuobj.style.top = (screen.availHeight-parseInt(menuobj.style.height))/2
		menuobj.style.left = (screen.availWidth-parseInt(menuobj.style.width))/2
	}
//	alert("The IFRAME is visible now .\nClick OK to see the the change")
	menuobj.style.visibility='visible';
//	alert("Now the menu is visible ..See how it covers the form element")
} 

function showProgressBar()
{

/*	document.getElementById('progressbar').style.visibility='visible';
//	document.getElementById('progressbar').style.display='inline';
	document.images['progressbarimage'].src=''
	setTimeout("document.images['progressbarimage'].src='images/progressbar.gif'",400)
	*/
//	document.getElementById('progressbar').innerHTML="<img border=0 src='images/progressbar.gif'>"

	var obj = (document.getElementById) ? document.getElementById('progressbar') : eval("document.all['progressbar']");
	setOnTop('progressbar')
//	obj.style.visibility='visible';
	if( navigator.userAgent.toLowerCase().indexOf("msie") != -1 )
		setTimeout("document.images['progressbarimage'].src='"+scriptpath+"progressbar.gif'",500)
}