function showDialog(ID,Horz,Vert) {
	var HorzShift=Horz;
	var VertShift=Vert;
	
	DivID=ID;
	
	document.getElementById(DivID).style.display='block';
	document.getElementById(DivID).style.visibility='hidden';
	
	if( typeof( window.innerWidth ) == 'number' ) {
		//Non-IE
		scrWidth = window.innerWidth;
		scrHeight = window.innerHeight;
	}
	else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
		//IE 6+ in 'standards compliant mode'
		scrWidth = document.documentElement.clientWidth;
		scrHeight = document.documentElement.clientHeight;
	}
	else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
		//IE 4/5 compatible
		if(document.body.scrollTop=='0') {
		document.body.scrollTop='1';
		}
		scrWidth = document.body.clientWidth;
		scrHeight = document.body.clientHeight;
	}
	
	DivWidth=document.getElementById(DivID).offsetWidth;
	DivHeight=document.getElementById(DivID).offsetHeight;
	
	var locationHorizCenter	= (scrWidth/2) - (DivWidth/2) + HorzShift;
	var locationVertCenter	= (scrHeight/2) - (DivHeight/2) + VertShift;
	
	if(scrWidth <= DivWidth) { //check horizontal placement
		locationHorizCenter = 0;
	}
	
	if(scrHeight <= DivHeight) { //check vertical placement
		locationVertCenter = 0;
	}
	
	if( typeof( window.pageYOffset ) == 'number' ) {
		//Netscape compliant
		scrollDown = window.pageYOffset;
		scrollRight = window.pageXOffset;
		document.getElementById(DivID).style.top=locationVertCenter+scrollDown+'px';
		document.getElementById(DivID).style.left=locationHorizCenter+scrollRight+'px';
	}
	else if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) ) {
		//DOM compliant
		scrollDown = document.body.scrollTop;
		scrollRight = document.body.scrollLeft;
		document.getElementById(DivID).style.top=locationVertCenter+scrollDown+'px';
		document.getElementById(DivID).style.left=locationHorizCenter+scrollRight+'px';
	}
	else if( document.documentElement) {
		//IE6 standards compliant mode
		scrollDown = document.documentElement.scrollTop;
		scrollRight = document.documentElement.scrollLeft;
		document.getElementById(DivID).style.top=locationVertCenter+scrollDown+'px';
		document.getElementById(DivID).style.left=locationHorizCenter+scrollRight+'px';
	}
	
	document.getElementById(DivID).style.visibility='visible';
	//document.getElementById(DivID).style.display='block';
}

function hideDialog(DivID) {
	//document.getElementById(DivID).style.visibility='hidden';
	document.getElementById(DivID).style.display='none';
}