function AutoFocus(currentId, nextId)
{
	var current = document.getElementById(currentId);
	var next = document.getElementById(nextId);
	if (current.value.length == current.maxLength)
	{
		next.focus();
	}
}

function ClearInput(objId)
{
	var objInput = document.getElementById(objId);
	if (objInput) {
		objInput.value = "";
	}
}

function openwin(eee) {
	var width = 950;
	var height = 500;
	var winxpos = (window.screen.availWidth - width)/2;
	var winypos = (window.screen.availHeight - height)/2;
	window.open (eee, "newwindow", "height="+height+", width="+width+", top="+winypos+", left="+winxpos+", toolbar=no, menubar=no, scrollbars=yes, resizable=no, location=no, status=no")
}

function openwin2(eee, width, height) {
	var winxpos = (window.screen.availWidth - width)/2;
	var winypos = (window.screen.availHeight - height)/2;
	window.open (eee, "newwindow", "height="+height+", width="+width+", top="+winypos+", left="+winxpos+", toolbar=no, menubar=no, scrollbars=yes, resizable=no, location=no, status=no")
}