ng5 = (document.getElementById) ? true:false
ns4 = (document.layers) ? true:false
ie4 = (document.all) ? true:false 
	

function openPop(w,h,webaddress,name,scrolls) {
	 	var winLeft = (screen.availWidth/2)-(w/2);
		var winTop = (screen.availHeight/2)-(h/2);
		var scroll = scrolls;
		var viewimageWin = window.open(webaddress,name,'left='+winLeft+',top='+winTop+',toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars='+scroll+',resizable=no,copyhistory=no,width='+w+',height='+h);
		viewimageWin.focus();
	}
	
function ShowCalendar(w,h,FormName, FieldName) {
	var curValue = eval("document."+FormName+"."+FieldName+".value");
	var winLeft = (screen.availWidth/2)-(w/2);
	var winTop = (screen.availHeight/2)-(h/2);
	window.open("DatePopup.aspx?getDate="+ curValue + "&FormName=" + FormName + "&FieldName=" + FieldName, "CalendarWindow", "width="+w+",height="+h+",left="+winLeft+",top="+winTop);
}

