/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */





 
             
var BrowserName=navigator["appName"];
if(BrowserName=="Microsoft Internet Explorer")
{
    BrowserName="ie";
   
}
 

        
var GlobalvariableForCheckBox=0;
var PageContainsError=false;

var lastRadioButtonIdname="";
var CurrentRadioButtonIdname="";
var CurrentChkObjectidName="";

var PrevChkObjectidName="";

function CheckRadioButton(RbObjectID)
{ 
    //alert("")
    //    msg ("inf_"+RbObjectID.id, "", "");
    validateRadio(RbObjectID,"inf_"+RbObjectID.id,true,"");
 
}

function UploadFile(fileOB)
{

    validateFile(fileOB,"inf_"+fileOB.id,true);
//    if(fileOB.value.length>10)
//    {
//        //alert("11111111111");
//        msg ("inf_"+fileOB.id, "", "");
//    }
//else
// {
//     msg ("inf_"+fileOB.id, "warn", "Upload File");
// }
}

function SelectSelectOption(selectOb)
{
	
    validateSelectbox(selectOb,"inf_"+selectOb.id,true);
	
}
function Selectption(selectOb)
{
	
    validateselect(selectOb,"inf_"+selectOb.id,true);
	
}   
	
/*	
function SelectSelectOption(selectOb)
{
	
	if(selectOb.id=='yearstart')
	{
		var id=document.getElementsByid(yearstart);
		if(----{
		msg ("inf_"+fileOB.id, "", "");
		   }
		
		else{
		  validateSelectbox(selectOb,"inf_"+selectOb.id,true);
		}
	}
 */
//    alert(selectOb.selectedindex)
//    if(selectOb.selectedindex>0)
//    {
//        //alert("11111111111");
//        msg ("inf_"+fileOB.id, "", "");
//  }  }
var isFocusSET=false;
var FocusOb;
var FocusObArray=[];
var isMultiForm=false;
var CurrentFormCount=0;
var CurrentFormName=0;
//function validateOnSubmitMultiForm(count){
//
//    //alert( document.forms[0].getElementsByTagName("input")[1].id);
//    isMultiForm=true;
//    CurrentFormCount=count;
//     alert(count)
//    validateOnSubmit();
//    alert("");
//    // alert(strMsgSummary);
//    if(strMsgSummary.length > 0)
//    {
//        //alert(strMsgSummary);
//        return false;
//    }
//}
function validateOnSubmitMultiForm(count){

    //alert( document.forms[0].getElementsByTagName("input")[1].id);
    isMultiForm=true;
    CurrentFormCount=count;
    //  alert(count)
    validateOnSubmit();
    // alert("");
    // alert(strMsgSummary);
    if(strMsgSummary.length > 0)
    {
        //alert(strMsgSummary);
        return false;
    }
}
var focusid="";
var focusfixed=false;
function validateOnSubmit(formname)
{
 
    PrevObName="";
    //  alert(formname.name)
    CurrentFormName=formname.name;
    // alert(CurrentFormName)
    
    //    for(i=1;i<document.forms.length;i++)
    //    {
    //        if(document.forms[i].name==formname.name)
    //            CurrentFormName=i;
    //    }
    // alert(CurrentFormName);
    // CurrentFormName=3;
    //CurrentFormName=formname.name;
    focusid="";
    focusfixed=false;
    //alert(focusfixed)
      
    FocusObArray=[];
    // alert(FocusCounter)
    FocusCounter=0;
    //alert("");
    strMsgSummary ="";
    
    
    
    lastRadioButtonIdname="";
    CurrentRadioButtonIdname="";
    CurrentChkObjectidName="";
    PrevChkObjectidName="";
    var obtag ;
    
    
   
      
    //if(isMultiForm)
    // {
   
    try{
        obtag = formname.getElementsByTagName("input");
      
    }catch(e)
    {
        alert(e)

    // obtag = formname.getElementsByTagName("input");
    }
  //alert(obtag);
    // obtag = document.forms[0].getElementsByTagName("input");
    //  alert("1111111111"+ obtag.length)
    //    }else
    //    {
    //        //Returns a list of elements of type "input" with the given tag name from StudentForm.jsp.
    //        obtag = document.getElementsByTagName("input");
    //    }

    //alert("11"+document.getElementById("txtSearchvalue").value)
    // alert("33"+formname.txtSearchvalue.value)
    // alert(obtag.length)
    for (var i=0; i < obtag.length; i++)
    {
		 
      
        //A elemObj is an object. The values associated with the object.
        //The given input tag will be stored in to elemObj.
        var elemObj = obtag[i];
        
        //validation for the text fields.
        //If the given input type is text
        
           
        if(elemObj.type=="text" )
        {      
            if(document.getElementById("inf_"+elemObj.id)!=null)
                document.getElementById("inf_"+elemObj.id).innerHTML="";


            //varivables declaration.
            var NameOfTxtFld=null;
            var ErrMessage=null;
            var Requirement=null;
              

            //checks for the alt text length of the input field.(if alt length > 0)
            if(elemObj.alt.length > 0)
            {
                    
                var elemid="inf_"+elemObj.id;
                //alt text will be split in to parts where ever the symbol "##" has taken place.
                var altValueTxtFld=elemObj.alt.split("##");

                //alt text will be splits in to 3 parts.
                 //alert(altValueTxtFld);
                for(var j = 0; j < altValueTxtFld.length; j++)
                {                    
                    NameOfTxtFld=altValueTxtFld[0];//first part of the alt text.(contains field title)
                   
                    // ErrMessage=altValueTxtFld[1];//second part of the alt text.(contains error message)
                    Requirement=altValueTxtFld[1];//third part of the alt text.(contains keyword "Mandatory" for validation)
                }
                //  alert(NameOfTxtFld);
                //if alt text contains "Mandatory" keyword then it validates for EmptyField.
                if(Requirement.toLocaleLowerCase()=="validate" )
                {
                    
                    ValidateEmpty(elemObj,elemid);
                //                    if(ValidateEmpty(elemObj,elemid))
                //                        {
                //                            continue;
                //alert("----");
                //                        }
                }
               // alert(Requirement.toLocaleLowerCase()=="validate");
              
                          
                if(Requirement.toLocaleLowerCase()=="validate" || elemObj.value!="" )

              
                {
                        
                          
                    //if textFldTitle1==userid.
                    //validates the username.
                    if(NameOfTxtFld == "userid")
                    {
                        validateUsername(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "isInteger")
                    {
                        isInteger(elemObj,elemid,true);
                    }

                    if(NameOfTxtFld == "validateName")
                    {          
                        validateName(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "validateCName")
                    {
                        validateCName(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "validateforwardtoafriendName")
                    {
                        validateforwardtoafriendName(elemObj,elemid,true,3,20);
                    }
				
                    if(NameOfTxtFld =="validatetextbox")
                    {
                        validatetextbox(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "text")
                    {
                        validatecategeroy(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "validateMoneyFormate")
                    {
                        validateMoneyFormate(elemObj,elemid,true);
                    }

				   
                    if(NameOfTxtFld == "HasEmailContent")
                    {
                        HasEmailContent(elemObj,elemid,true);
                    }
                  
                     if(NameOfTxtFld == "validtext")
                    {
                        validateGeneraltextbox(elemObj,elemid,true);
                    }
					   
                    if(NameOfTxtFld == "validatetext")
                    {
                        validatetext(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "middle")
                    {
                        validatemiddle(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "url")
                    {
                        validateurl(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "isWebSiteAddress")
                    {
                        isWebSiteAddress(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld=="iscotainonlyspaces")
                    {

                        iscotainonlyspaces(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld=="validateGeneraltextbox")
                    {
                        validateGeneraltextbox(elemObj,elemid,true);
                    }
                   
                    if(NameOfFld=="Email ID/TFP ID")
                    {
                        validateGeneraltextbox(elemObj,elemid,true);     
                    }
                    

                
                    if(NameOfTxtFld == "blog")
                    {
                        validateblog(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "address")
                    {
                        validateaddress(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "validateGeneral")
                    {
                        validateGeneral(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "alownumbersnotspace")
                    {
                        validate_alownumbersnotspace(elemObj,elemid,true);
                    }
                
                    //if textFldTitle1==dataOfBth.(DateOfBirth)
                    //validates the date.
                    // if(NameOfTxtFld=="date")
                    //  {
                    //       validateDate(elemObj,ErrMessage);
                    //   }

                    //if textFldTitle1==emailid.
                    //validates the emailid.
                    if(NameOfTxtFld=="emailid")
                    {
                         
                        validateEmail(elemObj,elemid,true);
                    
                    }
                    // alert(NameOfTxtFld);
                    if(NameOfTxtFld=="emailidusername")
                    {
                        validateEmail(elemObj,elemid,true);
                        // AjaxReturncontent="";
                        // alert(chekEmailAvailability(elemObj));
                        var information=chekEmailAvailability(elemObj);
                        try{
                            if(information.length>0)
                            {
                                msg ("inf_"+elemObj.id, "error",information );
                                setfocus(elemObj);
                            }
                        }catch(e)
                        {
                            
                        }
                         
                    //                        //alert(document.getElementById("inf_txtEmailid").innerHTML);
                    //                        //alert(AjaxReturncontent);
                    //                        AjaxReturncontent="";
                    //                        try{
                    //                            if(elemObj.id=="txtEmailid")
                    //                            {
                    //                                msg ("inf_"+elemObj.id, "error", AjaxReturncontent);
                    //                                setfocus(elemObj);
                    //                            }
                    //                        }catch(e){}

                    //                        //alert(AjaxReturncontent.length)
                    ////                        if(AjaxReturncontent.length==0)
                    ////                        {
                    ////                            validateEmail(elemObj.id,elemid,true);
                    ////                        }
                    //                       // else
                    //                        {
                    //                            msg ("inf_"+elemObj.id, "error", AjaxReturncontent);
                    //                            setfocus(elemObj);
                    //                        }

                    }

                

                    //if textFldTitle1==mutipleEmail.
                    //validates the mutipleEmail.
                    //if(NameOfTxtFld=="mutipleEmail")
                    // {
                    //     validateMultipleMails(elemObj,ErrMessage,Requirement);
                    // }

                    //if textFldTitle1==PhoneNumber.
                    //validates the PhoneNumber.
                    if(NameOfTxtFld == "Telnum")
                    {
                        validateTelnr(elemObj,elemid,true);
                    }

                    //if textFldTitle1==Mobilenumber.
                    //validates the Mobilenumber.
                    if(NameOfTxtFld == "Mobilenumber")
                    {
                        validateMobilenumber(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "Telnum")
                    {
                        validateTelnr(elemObj,elemid,true);
                    }
                    if(NameOfTxtFld == "Telephonenumber")
                    {
                        validateTelephonenumber(elemObj,elemid,true);
                    }

                    //if textFldTitle1==zipcode.
                    //validates the zipcode.
                    if(NameOfTxtFld == "zipcode")
                    {
                    // alert(formname.country.value)
                    //                        var selectedCountryName="";  
                    //                        try{
                    //                            selectedCountryName=formname.country.value;
                    //                        }catch(e)
                    //                        {
                    //                            selectedCountryName="";
                    //                        }
                    //           
                    //                        if(selectedCountryName!="other")
                    {
                           
                        validateZipcode(elemObj,elemid,true);
                    }
                    }
                }
            }

            //  alert(elemObj.id)
            try{
                
			       
			   var array_string=location.href.split("/admin/");   
			    if(array_string.length==1)
				{
                if(istextContainsEmailOrPhoneNumbber(elemObj,false))
                {


                 
            }
			}
  
            }catch(e)
            {
            //alert(e)
            }

             
        }
       
        //If the given input type is Password.
        if(elemObj.type=="password")
        {
            //alert("")
            var NameOfFld=null;
            var ErrMssg=null;
            var Reqiremt=null;
            if(elemObj.alt.length > 0)
            {
                var Pwdelemid="inf_"+elemObj.id;
                var PasswordFieldAltValue=elemObj.alt.split("##");
                for(var g = 0; g < PasswordFieldAltValue.length; g++)
                {
                    NameOfFld=PasswordFieldAltValue[0];//first part of the alt text.(contains field title)
                    //  ErrMssg=PasswordFieldAltValue[1];//second part of the alt text.(contains error message)
                    Reqiremt=PasswordFieldAltValue[1];//third part of the alt text.(contains keyword "Mandatory" for validation)
                }
                if(Reqiremt.toLowerCase()=="validate")
                {
                    ValidateEmpty(elemObj,Pwdelemid);
                    //alert(NameOfFld);
                    if(NameOfFld=="password")
                    {
                        validatePassword(elemObj,Pwdelemid,true);
                    }
                    if(NameOfFld=="VerifyPassword")
                    {
                        validateVerifyPassword(elemObj,Pwdelemid,true);
                    }
                }
            }
        }    // alert(elemObj.type);
        //If the given input type is file.
        if(elemObj.type=="file")
        {
            //  alert("");

            //varivables declaration.
            var fileFldName=null;
            var fileFldErrMsg=null;
            var fileFldReq=null;
            
            //checks for the alt text length of the input field.(if title length > 0)
            if(elemObj.alt.length >0)
            {
                var FileElemid="inf_"+elemObj.id;
                var filefieldAltValue=(elemObj.alt).split("##");
                for(var k = 0; k < filefieldAltValue.length; k++)
                {
                    fileFldName=filefieldAltValue[0];//first part of the alt text.(contains field title)
                    // fileFldErrMsg=filefieldAltValue[1];//second part of the alt text.(contains error message)
                    fileFldReq=filefieldAltValue[1];//third part of the alt text.(contains keyword "Mandatory" for validation)
                }
                //if alt text contains "Mandatory" keyword then it calls function "validateFile".
                //                if(fileFldReq=="Validate")
                //                {
                //                    validateFile(elemObj,FileElemid,true);
                //                }
                // alert(fileFldReq)
                //alert(elemObj.value);
                if(fileFldReq.toLowerCase()=="validate" || elemObj.value!="")
                {
                    if(fileFldName=="ValidateImageUpload")
                    {
                        //  alert("1111");
                        ValidateImageUpload(elemObj,FileElemid,true);
                    }
                    if(fileFldName=="ValidateAudioUpload")
                    {
                        //alert("1111");
                        ValidateAudioUpload(elemObj,FileElemid,true);
                    }
                    if(fileFldName=="ValidateVideoUpload")
                    {
                        //alert("1111");
                        ValidateVideoUpload(elemObj,FileElemid,true);
                    }
                    if(fileFldName=="ValidateswfimageUpload")
                    {
                        //alert("1111");
                        ValidateswfimageUpload(elemObj,FileElemid,true);
                    }
                    if(fileFldName=="ValidateResumeUpload")
                    {

                      
                        //alert("1111");
                        ValidateResumeUpload(elemObj,FileElemid,true);
                    }
                }
            }
        // alert(strMsgSummary)
        }
        if(elemObj.type=="radio")
        {
            //varivables declaration.
            var radioBtnErrMsg=null;
            var radioBtnReq=null;
            CurrentRadioButtonIdname=elemObj.name;
            var RadioElemid="inf_"+elemObj.id;
            //checks for the alt text length of the input field.(if title length > 0)
            if(elemObj.alt.length >0)
            {
                
                //alt text will be split in to parts where ever the symbol "##" has taken place.
                var radioBtnfieldAltVslue=(elemObj.alt).split("##");
                for(var m = 0; m < radioBtnfieldAltVslue.length; m++)
                {
                    radioBtnReq=radioBtnfieldAltVslue[1];//third part of the alt text.(contains keyword "Mandatory" for validation)
                    radioBtnErrMsg=radioBtnfieldAltVslue[2];
                }
                //if alt text contains "Mandatory" keyword then it calls the function "validateRadio".
                if(radioBtnReq.toLocaleLowerCase()=="validate")
                {
                    if(CurrentRadioButtonIdname!=lastRadioButtonIdname)
                    {
                        // IndexForRadioButton=0;
                        validateRadio(elemObj,RadioElemid,true,radioBtnErrMsg);
                    // newRadiobtn=false;
                    }
                }

            }
            lastRadioButtonIdname=CurrentRadioButtonIdname;

            
        }
        // alert(elemObj.type);
        //If the given input type is checkbox.
        if(elemObj.type=="checkbox")
        {
            // alert('---------dddddddd'+elemObj.alt.length);
            //varivables declaration.
            var checkboxFldname=null;
            var checkboxFldErrMsg=null;
            var checkboxFldReq=null;
            var checkboxMinLimit=null;
            var checkboxMaxLimit=null;
            CurrentChkObjectidName=elemObj.name;
            // alert(CurrentChkObjectidName);
            if(CurrentChkObjectidName!=PrevChkObjectidName)
            {
                GlobalvariableForCheckBox=GlobalvariableForCheckBox+1;
            }
            if(elemObj.alt.length >0)
            {
                var CheckBoxElemid="inf_"+elemObj.id;
                //alert(CheckBoxElemid);
                var checkboxfieldAltVlaue=(elemObj.alt).split("##");
                //alert(checkboxfieldAltVlaue);
                for(var n = 0; n < checkboxfieldAltVlaue.length; n++)
                {
                    checkboxFldname=checkboxfieldAltVlaue[0];//first part of the Title.(contains field title)
                    checkboxFldReq=checkboxfieldAltVlaue[1];//third part of the Title.(contains keyword "Mandatory" for validation)
                    checkboxFldErrMsg=checkboxfieldAltVlaue[2];
                    checkboxMinLimit=checkboxfieldAltVlaue[3];//minimum limit checkbox boxes has to be checked.
                    checkboxMaxLimit=checkboxfieldAltVlaue[4];//maximum limit.
                }         
                if(checkboxFldReq.toLocaleLowerCase()=="validate")
                {                   
                    validateCheckbox(elemObj,CheckBoxElemid,checkboxMinLimit,checkboxFldErrMsg,checkboxMaxLimit);
                //alert("sss");
               
                }
            }
            PrevChkObjectidName=CurrentChkObjectidName;
        }
    }
    //Returns a list of elements of type "textarea" with the given tag name from StudentForm.jsp.
    // var obtag1 = document.getElementsByTagName("textarea");

    var obtag1 = formname.getElementsByTagName("textarea");
                   
    for ( i=0; i < obtag1.length; i++)
    {
        
        try{
            //A elemObj is an object. The values associated with the object.
            //The given input tag will be stored in to elemObj.
            elemObj = obtag1[i];
            //varivables declaration.
            var textareaFldName=null;
            var textareaFldErrMsg=null;
            var textareaFldReq=null;
            var txtarId=elemObj.id;
            // alert(elemObj.getAttribute("alt"));
            var txtarIdHid=txtarId+"_"+"hidden";
            var TextBoxElemid="inf_"+elemObj.id;
            // alert(TextBoxElemid);
            var txtarhid=document.getElementById(txtarIdHid);
             //alert(txtarIdHid)
            var res="";
            try{
                res=(txtarhid.alt);
            }catch(e)
            {
                res= elemObj.getAttribute("alt")
            }
               
            var textareafieldAltValue=res.split("##");
 
               // alert(textareafieldAltValue);
          //  alert(textareafieldAltValue[1]);
                      for(var h = 0; h < textareafieldAltValue.length; h++)
                       {
                        textareaFldName=textareafieldAltValue[0];//first part of the alt text.(contains field title)
                        textareaFldErrMsg=textareafieldAltValue[1];//second part of the alt text.(contains error message)
                        textareaFldReq=textareafieldAltValue[2];//third part of the alt text.(contains keyword "Mandatory" for validation)
                     }  
                      
                    if(textareaFldName=="textarea")
                      {
                      
                      validatetextarea(elemObj,textareaFldReq,true);     
                         //alert(NameOfTxtFld);
                   
                      //alert('ravi---'+elemObj.name);             
                      //  validateforwardtoafriendName_textarea(elemObj,elemid,true,1,500);
                   
                    }
                     if(textareaFldName == "HasEmailContent")
                     {
          
                     HasEmailContent(elemObj,textareaFldReq,true);
           
                   }

            //alert("");
          if(textareaFldName == "ValidateContentLength")
            {
                 
                
                ValidateContentLength(elemObj,textareaFldReq,true);
            }
 
 
            try{
                if(istextContainsEmailOrPhoneNumbber(elemObj,false))
                {



            }  

            }catch(e)
            {
            //alert(e)
            }
             

        }catch(e){
 
        //alert(e)

        }
    }

    var obtag2 = formname.getElementsByTagName("select");
    //Returns a list of elements of type "select" with the given tag name from StudentForm.jsp.
    //var obtag2 = document.getElementsByTagName("select");
    for (i=0; i < obtag2.length; i++)
    {
        try{
            //alert("0000000");
            //A elemObj is an object. The values associated with the object.
            //The given input tag will be stored in to elemObj.
            elemObj = obtag2[i];
            // alert(elemObj.id);
            //varivables declaration.
            var selectboxFldName=null;
            var selectboxFldErrMsg=null;
            var selectboxFldReq=null;
            //get select element id to variable "selId".
            var selId=elemObj.id;
            //concatinate "selId" with "_" and "hidden" to variable "selIdHid".
            var selIdHid=selId+"_"+"hidden";
            var SelElemId="inf_"+elemObj.id;
            //to get hidden element id pass the variable "selIdHid" to the variable hid.
            var hid=document.getElementById(selIdHid);
            //get the alt text to "res1".
            var res1=(hid.alt);
            // res1 will be split in to parts where ever the symbol "##" has taken place.
            var seletboxfieldAltValue=res1.split("##");
            for(var b = 0; b < seletboxfieldAltValue.length; b++)
            {
                selectboxFldName=seletboxfieldAltValue[0];//first part of the alt text.(contains field title)
                // selectboxFldErrMsg=seletboxfieldAltValue[1];//second part of the alt text.(contains error message)
                selectboxFldReq=seletboxfieldAltValue[1];//third part of the alt text.(contains keyword "Mandatory" for validation)
            }
            // alert(selectboxFldReq+"-"+elemObj.id)
            // a/lert(selectboxFldName)
            //if alt text contains "Mandatory" keyword then it calls the function "validateSelectbox".
            if(selectboxFldName=="validateYearRange")
            {
                
                validateYearRange("yearstart","yearend") 
            }
            
            if(selectboxFldReq.toLocaleLowerCase()=="validate")
            {
                // alert("0000000");
                validateSelectbox(elemObj,SelElemId,true);
            //            if(selectboxFldName=="date")
            //                {
            //                    validateCalenderDate(elemObj,SelElemId,true);
            //                }
            }
            if(selectboxFldReq=="valid")
            {
                validateselect(elemObj,SelElemId,true);
            }
            //if selectboxFldTitle1=="selectMultiple" it calls the function "validateMultipleSelect".
            if(selectboxFldName=="selectMultiple" && elemObj.multiple==true)
            {
                validateMultipleSelect(elemObj,SelElemId,true);
            }
        }catch(e)
        {
        //alert(e)
        }
    }
    //alert(strMsgSummary);
    // return false;
    
    try{
        // alert('sdfsdfsdfsdfds');
        validateDOBOnSelection();
    }catch(e){}
    //alert('------f-----sdfsdfsdfsdfds');
    try{
        // alert('-----------sdfsdfsdfsdfds');
        validate_dateOnSelection();
    }catch(e){}
    
    try{
        //alert(focusid)
        document.getElementById(focusid).select();
        document.getElementById(focusid).focus();
        document.getElementById(focusid).className="error_focus";

    //document.getElementById(focusid).style.border="1";
    // document.getElementById(focusid).style.border="#FFFFFF";
    }catch(e)
    {

    }
    //alert(focusid);
    //alert("strMsgSummary"+strMsgSummary);
  
    if(strMsgSummary.length > 0)
    {
        //  alert(strMsgSummary);
        //alert(focusid);
        try{
            document.getElementById(focusid).focus();
        }catch(e){
        //alert(e)
        }
        return false;
    }
    
    //    alert(FocusCounter)
    //    alert(FocusObArray)
   
    return true;
}