 /////////////////////////////Anthem Scripts////////////////////////////////////////////////
 function Anthem_PreCallBack() {
			//if (!confirm("Are you sure you want to get the current time?")) {
			//	return false;
			//}
			
			var loading = document.createElement("div");
			loading.id = "loading";
			loading.style.color = "White";
			loading.style.backgroundColor = "red";
			loading.style.paddingLeft = "5px";
			loading.style.paddingRight = "5px";
			loading.style.position = "absolute";
			loading.style.right = "20px";
			loading.style.top = "20px";
			loading.style.zIndex = "9999";
			loading.innerHTML = "<font face=tahoma size=3><strong>Loading...</strong></font>";
			document.body.appendChild(loading);
		}
		function Anthem_CallBackCancelled() {
			//alert("Your call back was cancelled!");
			
		}
		function Anthem_PostCallBack() {
			var loading = document.getElementById("loading");
			document.body.removeChild(loading);
			
		}
//		function Anthem_Error(result) {
//					alert('Error In Application: \n' + result.error);
//					
//				}
 /////////////////////////////////////////////////////////////////////////////////////////////      
        function getconfirm(msg)
        {
           return(confirm(msg));
        }
////////////////////////////////////////////////////////////////////////////////////////////////////////////////		
        function GetObjID()
        {        
                
                var arr = objRowClicked.id;
				var id="";
				id=arr.substr(arr.lastIndexOf("_")+1);
				return id
		} 
////////////////////////////////////////////////////////////////////////////////////////////
	function SetCtrlDisabality(objContainer, ability)
	{
		for(i=0; i <= objContainer.all.length - 1; i++)
		{
			var ctrl = objContainer.all(i);
			if (ctrl.type == null  || ctrl.type == "button" )
			{
				ctrl.disabled = ability;
				
			}
			else if (ctrl.type == "text" || ctrl.type == "textarea")
			{
				ctrl.disabled = ability;
			}
			else if (ctrl.type == "select" )
			{
				ctrl.disabled = ability;
			}
		}
	}
		

////////////////////////////////////////////////////////////////////////////////////////////////////////////////
 	var objRowClicked;
	var objRowOvered;
	var CssLast = "";
	var objCurrentStyle;
	    
	var ItemCss="DgItem";
	var AlternateItemCss="DgAlt";
	var OverItemCss="DgOver";	
	var SelectItemCss="DgSItem";
	
	
	function RowMouseOver(obj)
	{
	    
		var strKind = obj.className;
	    objCurrentStyle=obj.className
		if (strKind == ItemCss || strKind == AlternateItemCss)		
		{	
			objCurrentStyle=obj.className
		}
		
		if (obj.className != SelectItemCss)
		{	
			obj.className=OverItemCss;
		}
	}
	function RowMouseOut(obj)
	{	    
		var strKind = obj.className;
		
		if (obj.className != SelectItemCss)
		{		
		    obj.className=objCurrentStyle;
		}
	}

	
	function RowClick(obj)
	{	   
		try
		{
			if(objRowClicked == obj) return;
			objRowClicked.className=CssLast;
		}
		catch(e)
		{}
	
		CssLast = (obj.className == AlternateItemCss) ? AlternateItemCss : ItemCss;
		obj.className=SelectItemCss;
		objRowClicked = obj;
		
		window.returnValue = GetObjID();
		self.close();

	}
 
///////////////////////////////////////////////////////////////////////////////////////////////////////////////
 
    function ShowLookUp(LT,objRetVal,UL,WP)
	{	
		 try
		  {	  
			var gotValue;
	       
			var WindowProperty;
			if (WP==null) 
				WindowProperty="center:yes;dialogHeight:600px;dialogWidth:800px;status:no;";
			else
				WindowProperty=WP;   
	          
			gotValue = showModalDialog(UL, "", WindowProperty);
		   	   
			if(gotValue!=null && objRetVal!=null)
				document.all(objRetVal).value=gotValue;
			return gotValue;
	      }
	      catch(e)
	      {
	        alert(e.message);
	      }
	  } 
///////////////////////////////////////////////////////////////////////////////////////////////////////////////?	  	
   //function ReturnLookUpValue()
	//   {
	//		var retval;
	//		retval=window.event.srcElement.value;
	//			
	//	    window.returnValue= retval;
	//        self.close()
	 // }
///////////////////////////////////////////////////////////////////////////////////////////////////////////////?
