
function setFieldValue(chkBox, fileName) {
	sField = fileName + "__" + chkBox.name
	formField = document.getElementById(sField);
	
	if(chkBox.checked) { formField.value = "Y"; }
	else { formField.value = ""; }

}

function OpenInfoWindow(sUrl, iWidth, iHeight)
{
	//iHeight Override
	iHeight = 515
	window.open(sUrl,'','status=no,scrollbars=yes,location=no,menubar=no,toolbar=no,resizeable=yes,width='+iWidth+',height='+iHeight+',top=10,left=100');
	}
function Hilight(oObj, bState)
{
  if (bState)
  { 
    oObj.className="Hilite"; 
  }
  else 
  {
    oObj.className="Data"; 
  }
}

function RefreshClose()
	{
		opener.location.reload(true);
		window.close();
	}
	
function CheckPopupAllowed ()
	{
		winHandle=window.open('zzPopuptest.htm' + "?newwin=true", "_top", "width="+wwidth+",height="+wheight+",location=0,menubar=0,resizable=no,scrollbars=no,status=yes,titlebar=no,dependent=yes");
		if(winHandle==null){
			alert("Error: While Launching New Window...nYour browser maybe blocking up Popup windows. nn  Please check your Popup Blocker Settings");
		}
	}



function getPage(sPage, sHost, sServer, sReferer, sSoftware){
	var xmlHttp;
	sPage+="?scrWidth="+window.screen.width+"&scrHeight="+window.screen.height+"&sHost="+sHost+"&sServer="+sServer+"&sReferer="+sReferer+"&sSoftware="+sSoftware
	// Uncomment line below to make every call unique and bypass cache
	
try{    
	// Firefox, Opera 8.0+, Safari    
		xmlHttp=new XMLHttpRequest();
		xmlHttp.overrideMimeType('text/xml')   
	}catch (e){
	// Internet Explorer
		try{
			xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
		}catch (e){
			try{
				xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
			}catch (e){
				alert("Your browser does not support AJAX!");
				return false;        
			}      
		}    
	}	
	//alert(xmlHttp.onreadystatechange)
	xmlHttp.onreadystatechange=function(){
		//alert(xmlHttp.status)
		if(xmlHttp.readyState==4){
			try{
				//alert("how"+xmlHttp.responseText)
				//Use Below to show outputted html as code
				//document.getElementById("look").innerText=xmlHttp.responseText;
				
				//Use Below to show outputted HTML
				//document.getElementById("MainContentTable").style.top = '0px'
				//prompt('',xmlHttp.responseText)
				//document.getElementById("look").innerHTML=xmlHttp.responseText;
				
				//document.getElementById("look").style.visibility="visible"
			}catch(err){
				//document.getElementById("look").innerHTML="Error: " + err.description
			}
		}
	}
	//alert(sPage)
	try{
	xmlHttp.open("GET",sPage,true);
	}catch(e){alert(e.description)}
	
	//alert("what"+xmlHttp.responseText);
	
	xmlHttp.send(null);
	
}
