function RestrictLength(controlname, maxLimit)
{
		
	if (document.getElementById(controlname).value.length > maxLimit)
	{	
		return false;
	}
}

function  CheckData_Null(strControlName,strMsg) 
{		
	if(document.getElementById(strControlName).value=="")
	{				
		alert (strMsg);
		document.getElementById(strControlName).focus();	
		return false;
	}	
	return true;
}

function button_save_extra_onclick()
{
	return true;
}

function button_new_extra_onclick()
{
	return true;
}

///textbox:0, combo:1, checkbox :2 , 3: hideen control
function ClearControl(strControlName,kindcontrol)
{
	if(kindcontrol==0)
	{
		document.getElementById(strControlName).value="";
	}
	if(kindcontrol==1)
	{
		document.getElementById(strControlName).value="";
	}
	if(kindcontrol==2)
	{
		document.getElementById(strControlName).checked=false;
	}
	if(kindcontrol==3)
	{
		document.getElementById(strControlName).value="";
	}
}
function Show_DIV(ctr)
{
	if (document.getElementById(ctr).style.display=='none')
	{
		document.getElementById(ctr).style.display='';
	}
	else
	{
		document.getElementById(ctr).style.display='none';
	}
	
}
function openWinNews(vLink, vName, vHeight, vWidth)
{
	winDef = 'status=no,resizable=no,scrollbars=no,toolbar=no,location=no,fullscreen=no,titlebar=no,height='.concat(vHeight).concat(',').concat('width=').concat(vWidth).concat(',');
	winDef = winDef.concat('top=').concat((screen.height - vHeight)/2).concat(',');
	winDef = winDef.concat('left=').concat((screen.width - vWidth)/2);
	newwin = open(vLink, vName, winDef);
}
function ProcessMouseOutOnMenu_DN(obj,MouseDown_CSS,MouseOut_CSS)
	{		
		if(obj.clicked=="1")
		{
			obj.className=MouseDown_CSS;
		}
		else
		{
			obj.className=MouseOut_CSS;
		}
		
	}
