	function E_Me(c1,c2,c3,c4,c5,c6,c7,c8) 	{
		strAdds = new Array(c1,c2,c3,c4,c5,c6,c7,c8);
		strUser = "";
		strMailTo = "";
		for (x=0;x<strAdds.length;x++) {
			if (strAdds[x]!=null)
				strUser += strAdds[x];
		}
		//alert("mai"+"lto:"+strUser+"@"+"Root"+"."+ "com");
		strMailTo = "mai"+"lto:"+strUser+"@"+"Root"+"."+ "com";
		document.location = strMailTo;
	}

	function winopen(url)
	{
	window.open(url,"","resizable=yes,scrollbars=yes,height=527,width=600,left=0,top=0");
	}

	
	function setForm() 	{
		rtn=true;	
		document.loginForm.action="https://secure.netlinksolution.com/portal/?action=JLoginUser";
		return (rtn);
	}


	function setForm4() 	{
		rtn4=true;	
		document.loginForm4.action="https://secure.netlinksolution.com/portal/?action=JLoginUser";
		return (rtn4);
	}


	function setForm2() 	{
		rtn2=true;	
		document.loginForm2.action="https://secure.netlinksolution.com/portal/?action=JLoginUser";	
		return (rtn2);
		
	}

	function setForm_ap() 	{
		rtn_ap=true;	
		document.loginForm_ap.action="https://app.bill.com/Login";
		return (rtn_ap);
	}





	function toggleForm(radio_obj) 
	{
		showForm = document.getElementById(radio_obj.value);
		showForm.style.visibility="visible";
		showForm.style.display="inline";
		if(radio_obj.value == "form_docs") { 
			alert("hide accounting");
			document.getElementById("form_accounting").color="red";
			document.getElementById("form_accounting").visibility="hidden"; 
			document.getElementById("form_accounting").display="none"; 
		} else {
			alert("hide docs");
			document.getElementById("form_docs").color="red";
			document.getElementById("form_docs").visibility="hidden"; 	
			document.getElementById("form_docs").display="none"; 
		}
	}

	function activateForm(radio_obj) 
	{
		var showDiv="";
		var hideDiv="";
		var hideDiv2="";
		var hideDiv3="";
		var hideDiv4="";

		if(radio_obj.value == "form_docs") { 
			showDiv = "form_docs";
			hideDiv = "form_accounting";
			hideDiv2 = "form_quickbooks";
			hideDiv3 = "form_sharefile";
			hideDiv4 = "form_ap";
		} 
		else if(radio_obj.value == "form_accounting") { 
			showDiv = "form_accounting";
			hideDiv = "form_docs";
			hideDiv2 = "form_quickbooks";
			hideDiv3 = "form_sharefile";
			hideDiv4 = "form_ap";
		} 
		else if(radio_obj.value == "form_sharefile") { 
			showDiv = "form_sharefile";
			hideDiv = "form_docs";
			hideDiv2 = "form_quickbooks";
			hideDiv3 = "form_accounting";
			hideDiv4 = "form_ap";

		} 
		else if(radio_obj.value == "form_ap") { 
			showDiv = "form_ap";
			hideDiv = "form_docs";
			hideDiv2 = "form_quickbooks";
			hideDiv3 = "form_accounting";
			hideDiv4 = "form_sharefile";

		} 
		else {
			showDiv = "form_quickbooks";
			hideDiv = "form_docs";
			hideDiv2 = "form_accounting";
			hideDiv3 = "form_sharefile";
			hideDiv4 = "form_ap";
		} 
	/*
	   iState = 1; // 1 visible, 0 hidden
	   var obj = document.layers ? document.layers[showDiv] :
		document.getElementById ?  document.getElementById(showDiv).style :
		document.all[showDiv].style;
	   obj.visibility = document.layers ? (iState ? "show" : "hide") :
		(iState ? "visible" : "hidden");
	   obj.display  = "block";
	*/
	   document.getElementById(showDiv).style.visibility = "visible";
	   document.getElementById(showDiv).style.display = "inline";
	   document.getElementById(hideDiv).style.visibility = "hidden";
	   document.getElementById(hideDiv).style.display = "none";
		document.getElementById(hideDiv2).style.visibility = "hidden";
	   document.getElementById(hideDiv2).style.display = "none";
		document.getElementById(hideDiv3).style.visibility = "hidden";
	   document.getElementById(hideDiv3).style.display = "none";
	   document.getElementById(hideDiv4).style.visibility = "hidden";
	   document.getElementById(hideDiv4).style.display = "none";

	}

	function submitViaEnter(evt) {
	alert("submitViaEnter(" + evt + ")");
		evt = (evt) ? evt : event;
		var target = (evt.target) ? evt.target : evt.srcElement;
		var form = target.form;
		var charCode = (evt.charCode) ? evt.charCode : ((evt.which) ? evt.which : evt.keyCode);
		if (charCode == 13 || charCode == 3) {
			connect(form);
			return false;
		}
		return true;
	}
	 
	 
	function connect(f) {
		//alert("connect(" + f.mapdrives.checked + ")");
		var params = "?options=1&username="+f.username.value+"&screen=0";
		if (f.mapdrives.checked) params += "&mapdrives=true";
		var url = "https://www.rightnetworks.com/tsweb/connect.jsp" + params;
		var d = new Date();
		var newWindow = window.open(url, "ConnectWindow"+d.getMilliseconds(), "left=0,top=0,resizable");
		//alert(window.location + "\n\n" + url);
		//window.location =  url;
		newWindow.focus();
	}
	function openNote()
	 { 
	 
	 var agt=navigator.userAgent.toLowerCase(); 
	 var is_aol   = (agt.indexOf("aol") != -1);

	 leftpos=0;
	 if (screen) {
	   leftpos=screen.width/2 - 300;
	 } 

	 if (is_aol) {
	   var s = " ";
	   s=document.calculator.sJavaScriptReport('HTML');
		document.write(s);
	 }
	 else {
	   var OpenWindow=window.open("","newwin","toolbar=yes,menubar=yes,location=no,directories=no,status=no,scrollbars=yes,resizable=yes,copyhistory=no,width=600,height=380,left="+leftpos+",top=20");
	   var s = " ";
	   s=document.calculator.sJavaScriptReport('HTML');
	   OpenWindow.document.write(s);
	   OpenWindow.document.close(); 
	   OpenWindow.focus();
	 }
}

