function MapAddress(Country,Address,City,State,Zip){var url="http://www.mapquest.com/maps/map.adp?";url += ("country=" + Country);url +=("&address=" + Address);url +=("&city=" + City);url +=("&state=" + State);url +=("&zipcode=" +Zip);url+="&homesubmit=Get+Map"window.open(url); }function pushoutdate(dobj,numdays){//Pushing out the FlagDate by 3 daysmyDate=new Date(dobj.value);myDate=new Date(myDate.getTime() + numdays*24*60*60*1000)var y =myDate.getFullYear();var m = myDate.getMonth();     // integer, 0..11 var d = myDate.getDate();      // integer, 1..31//parent.Content.document.getElementById("datamain");m+=1if (m < 10){m="0" + m}if (d < 10){d="0" + d}return (m + "/" + d + "/" + y)}function createSelectField(name, listtext, listval,def,chgevent) {//Set defaults for null or undefined input parameters:if( name+"" == null || name+"" == "undefined" || name+"" == "" )name = "";if( listtext+"" == null || listtext+"" == "undefined" || listtext+"" == "" )listtext= new Array("");if( listval+"" == null || listval+"" == "undefined" || listval+"" == "" )listvalue = new Array("");if( def+"" == null || def+"" == "undefined" || def+"" == "" )def = "";name = name + "_edit"//Create HTML for select fieldvar htmlCode = "";htmlCode += "<SELECT name='" + name+ "'id='" + name+ "'onchange='" + chgevent + "'>";for(var i = 0; i < listval.length; i++) {if(listval[i] == def)htmlCode += "<OPTION value='" + listval[i] +"' selected>" + listtext[i] + "</OPTION>";elsehtmlCode += "<OPTION value='" + listval[i] +"'>" + listtext[i] + "</OPTION>";}htmlCode += "</SELECT>";//alert(htmlCode);return( htmlCode );} function inStr(beginning, word1, word2) {check1 = new String(word2);returnInStr = word1.indexOf(word2, (beginning - 1)) + 1;return returnInStr; }function createCheckboxField(name,listtext, listval,def, chgevent) {//Set defaults for null or undefined input parameters:if( name+"" == null || name+"" == "undefined" || name+"" == "" )name = "";if( listval+"" == null || listval+"" == "undefined" || listval+"" == "" )list = new Array("");if( listtext+"" == null || listtext+"" == "undefined" || listtext+"" == "" )list = new Array("");if( def+"" == null || def+"" == "undefined" || def+"" == "" )def = "";name = name + "_edit"//Create HTML for select fieldvar htmlCode = "";for(var i = 0; i <= listval.length -1; i++) {var idname= name + "_" + listval[i]; //Need to see if the listval[i] is contained in the listif(inStr(1,def,listval[i])){htmlCode += "<input type='checkbox' checked id='" + idname + "' name='" + name +"' value='" + listval[i] + "' onclick='javascript:" + chgevent +"'><LABEL ID='" + idname + "_label' FOR='" + idname + "'>" + listtext[i]+"</LABEL><BR>"}else{htmlCode += "<input type='checkbox' id='" + idname + "' name='" + name +"' value='" + listval[i] + "' onclick='javascript:" + chgevent +"'><LABEL ID='" + idname + "_label' FOR='" + idname + "'>" + listtext[i]+"</LABEL><BR>"}}return(htmlCode);} function createCheckboxFieldTable(name,listtext, listval,def, chgevent,row,header,onclickevt) {//Set defaults for null or undefined input parameters:if( name+"" == null || name+"" == "undefined" || name+"" == "" )name = "";if( listval+"" == null || listval+"" == "undefined" || listval+"" == "" )list = new Array("");if( listtext+"" == null || listtext+"" == "undefined" || listtext+"" == "" )list = new Array("");if( def+"" == null || def+"" == "undefined" || def+"" == "" )def = "";//alert("count: " + listtext.length + "----" +listtext);name = name + "_edit"//Create HTML for select fieldvar htmlCode = "";htmlCode+="<table style='border: 1px solid #000000;width:600 px;margin-bottom:10px'>"if (header !=""){htmlCode +=('<TR style="background-color:#EEEFED;"><TD colspan="'+row + '">' + header +'</TD></TR>')}col=-1for(var i = 0; i <= listval.length -1; i++) {    if (col==-1 ){        htmlCode+="<TR>"        col=0        //  alert("<tr>" +col);      }      if (col==row){          htmlCode+="</TR><TR>"              col=0	//	alert("equal row");          }  //    if(col > row){    //  col=0;     // }var idname= name + "_" + listval[i]; if(inStr(1,def,listval[i])){//htmlCode += "<input type='checkbox' checked name='" + name +"' value='" + listval[i] + "onclick='" + chgevent +"'>"+ listtext[i]+ "<BR>"htmlCode += "<td><input type='checkbox' onclick='" + onclickevt + "' checked id='" + idname + "' name='" + name +"' value='" + listval[i] + "' onclick='javascript:" + chgevent +"'><LABEL ID='" + idname + "_label' FOR='" + idname + "'>" + listtext[i]+"</LABEL></td>"}else{//htmlCode += "<input type='checkbox' name='" + name +"' value='" + listval[i] + "onclick='" + chgevent +"'>"+ listtext[i]+"<BR>"htmlCode += "<td><input type='checkbox' onclick='" + onclickevt + "' id='" + idname + "' name='" + name +"' value='" + listval[i] + "' onclick='javascript:" + chgevent +"'><LABEL ID='" + idname + "_label' FOR='" + idname + "'>" + listtext[i]+"</LABEL></td>"}col+=1//alert("count" +col);}if (col > 0){htmlCode+="</TR>"}htmlCode+="</table>"return(htmlCode);} function createRadioField(name, listtext,listval, def, chgevent) {//Set defaults for null or undefined input parameters:if( name+"" == null || name+"" == "undefined" || name+"" == "" )name = "";if( listval+"" == null || listval+"" == "undefined" || listval+"" == "" )list = new Array("");if( listtext+"" == null || listtext+"" == "undefined" || listtext+"" == "" )list = new Array("");if( def+"" == null || def+"" == "undefined" || def+"" == "" )def = "";name = name + "_edit"//Create HTML for select fieldvar htmlCode = "";for(var i = 0; i <listval.length ; i++) {  var idname= name + "_" + listval[i]; if(listval[i] == def){htmlCode += "<input type='radio' checked id='" + idname + "' name='" + name +"' value='" + listval[i] + "' onclick='javascript:" + chgevent +"'><LABEL ID='" + idname + "_label' FOR='" + idname + "'>" + listtext[i]+"</LABEL><BR>"}else{htmlCode += "<input type='radio' id='" + idname + "' name='" + name +"' value='" + listval[i] + "' onclick='javascript:" + chgevent +"'><LABEL ID='" + idname + "_label' FOR='" + idname + "'>" + listtext[i]+"</LABEL><BR>"}}return(htmlCode);} function setSelectOptions(name, obj,doc){     var fld_dsp = doc.getElementById(name + "_Dsp");	var fld_val = doc.getElementById(name);   	if (obj.tagName=='SELECT'){		fld_dsp.value=obj.options[obj.selectedIndex].text;				fld_val.value=obj.options[obj.selectedIndex].value;	}	if (obj.tagName=='INPUT') {		etype=obj.type;		if (etype=='checkbox'){		       if (obj.checked){				var lfld=obj.name +"_"+obj.value + "_label";				var lobj=doc.getElementById(lfld);								fld_dsp.value=lobj.innerText;				fld_val.value=obj.value;			}			else{				fld_dsp.value="";			}		}	    if (etype=="radio"){				var lfld=obj.name +"_"+obj.value + "_label";	   			var lobj=doc.getElementById(lfld);				fld_dsp.value=lobj.innerText;				 fld_val.value=obj.value;			}	}}