 
function taLimit() {
	var taObj=event.srcElement;
	if (taObj.value.length==taObj.maxLength*1) return false;
}

function taCount(visCnt) { 
	var taObj=event.srcElement;
	if (taObj.value.length>taObj.maxLength*1) taObj.value=taObj.value.substring(0,taObj.maxLength*1);
	if (visCnt) visCnt.innerText=taObj.maxLength-taObj.value.length;
}

function textCounter(field, maxlimit) {
	if (field.value.length > maxlimit) {
		field.value = field.value.substring(0, maxlimit);
		alert("This field cannot contain more than " + maxlimit + " characters");
	}
}
function hideShow(div,icon,swaptext,title)
{ 
	if(document.getElementById(div).style.display == 'none')
	{ 
		document.getElementById(div).style.display = '';
		document.images[icon].src = '/_resources/images/xtree/hide.gif';
		document.getElementById(swaptext).innerText = 'Hide ' + title;	
	}
	else
	{
		document.getElementById(div).style.display = 'none';
		document.images[icon].src = '/_resources/images/xtree/show.gif';
		document.getElementById(swaptext).innerText = 'Show ' + title;	
	}
} 
function cancel() {
	 history.go(-1);
}
function gohere(gotoURL) {
	 window.location = gotoURL;	
}
function hov(loc,cls){
   if(loc.className)
      loc.className=cls;
}
function NewWindow(mypage, myname, w, h) {
	var winl = (screen.width - w) / 2;
	var wint = (screen.height - h) / 2;
	winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',resizable,scrollbars,toolbar'
	win = window.open(mypage, myname, winprops)
	if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }

}
 