
function sizeCheck()
{	
	if ( screen.width <= 800 || screen.height <= 600 )
	{
			document.location.href = "Default.aspx?size=" + screen.width + "x" + screen.height;
	}
}

function search()
{	
	__doPostBack('_ctl0$topHeaderMenu$lnkSearch','');
}

function ShowHideDivs(show, hide)
{
	ShowDiv(show);
	HideDiv(hide);
}

function ShowDiv(div)
{	
	var tmpPanel;

	if ( document.getElementById )
	{
		tmpPanel = document.getElementById(div)
		
		if ( tmpPanel != null )
		{						
			tmpPanel.style.display = "";
			tmpPanel.style.visibility = "visible";			
		}						
	}
}

function HideDiv(div)
{	
	var tmpPanel;
	
	if ( document.getElementById )
	{
		tmpPanel = document.getElementById(div)
		
		if ( tmpPanel != null )
		{						
			tmpPanel.style.display = "none";
			tmpPanel.style.visibility = "hidden";			
		}						
	}
}

function ShowHide(div)
{
	var tmpPanel;
		
	if ( document.getElementById )
	{
		tmpPanel = document.getElementById(div)
		
		if ( tmpPanel != null )
		{											
			if ( tmpPanel.style.display == "none" || tmpPanel.style.visibility == "hidden" )
			{
				ShowDiv(div);
			}
			else
			{
				HideDiv(div);
			}
		}
	}
}

function ShowHideGroup(div, id)
{	
	HideDiv('divAE_' + id);
	HideDiv('divFJ_' + id);
	HideDiv('divKO_' + id);
	HideDiv('divPT_' + id);
	HideDiv('divUZ_' + id);
	
	ShowDiv(div);
}

function ShowMenuDropDown(div)
{	
	ShowDiv(div);
}

function HideMenuDropDown(div)
{	
	HideDiv(div);
}

function ShowLeftBar()
{	
	ShowDiv('divPanel');
}

function HideLeftBar()
{
	HideDiv('divPanel');		
}

function ChkNumeric(strString)
{
	var strValidChars = "0123456789";
	var i;
	var strChar;
	var blnResult = true;

	for (i = 0; i <= strString.length; i++){
		strChar = strString.charAt(i);
		if (strValidChars.indexOf(strChar) == -1) blnResult = false;
	}
	
	return blnResult;
}

function verify(f)
{
	var msg;
	var empty_fields
}

var visibleDiv = null;

function ShowAlert( text )
{
	alert(text)
}
	
function ShowHelpText(id, marker)
{		
	var divToShow;	
	
	divToShow = document.getElementById('helpDiv_' + id );			
	divToShow.style.display='block';			
	divToShow.style.top = marker.style.top;
	divToShow.style.visibility = 'visible';		
	if(divToShow.offsetLeft + divToShow.offsetWidth > screen.width) {
		divToShow.style.left = divToShow.offsetLeft - divToShow.offsetWidth - marker.offsetWidth;
	}
	visibleDiv = divToShow;
}

function HideHoverText(id, marker)
{
	if( visibleDiv ) {
		visibleDiv.style.visibility = 'hidden';
		visibleDiv.style.display = 'none';
	}
	
}

function SetStyle(id, newClass) {
	identity=document.getElementById(id);
	identity.className=newClass;
}

function SetVisibility(id, visible) {
	if (visible) {
		SetStyle(id, "visibleElement");
	}
	else {
		SetStyle(id, "hiddenElement");
	}
}