﻿// JScript File
function validate()
{
//      if(document.getElementById("txtCompanyDes").value=="")
//      {
//           alert("Please Enter Company Description");
//           document.getElementById("txtCompanyDes").focus();          
//           //document.getElementById("txtCompanyDes").style.borderColor="Red";
//           return false;
//      }
//      if(document.getElementById("txtCompanyDes").value.length>5000)
//       {
//           alert("Maximum 1000 Characters Are Allowed In \nCompany Description Field");
//           document.getElementById("txtCompanyDes").focus();
//           //document.getElementById("txtCompanyDes").style.borderColor="Red";
//           return false;
//       }
//       if(document.getElementById("txtBenefit").value=="")
//       {
//           alert("Please Enter Company Benefit");
//           document.getElementById("txtBenefit").focus();
//           ///document.getElementById("txtBenefit").style.borderColor="Red";
//           return false;
//       }
//       if(document.getElementById("txtBenefit").value.length>5000)
//       {
//           alert("Maximum 1000 Characters Are Allowed In \nCompany Benefit Field");
//           document.getElementById("txtBenefit").focus();
//           //document.getElementById("txtBenefit").style.borderColor="Red";
//           return false;
//       }
//       if(document.getElementById("txtJobDesc").value=="")
//       {
//           alert("Please Enter Job Description");
//           document.getElementById("txtJobDesc").focus();
//           //document.getElementById("txtJobDesc").style.borderColor="Red";
//           return false;
//       }
//       if(document.getElementById("txtJobDesc").value.length>5000)
//       {
//           alert("Maximum 1000 Characters Are Allowed In \nJob Description Field");
//           document.getElementById("txtJobDesc").focus();
//           //document.getElementById("txtJobDesc").style.borderColor="Red";
//           return false;
//       }       
//       if(document.getElementById("txtJobName").value=="")
//       {
//           alert("Please Enter Job Name");
//           document.getElementById("txtJobName").focus();
//           //document.getElementById("txtJobName").style.borderColor="Red";
//           return false;
//       }
//       if(document.getElementById("txtDesignation").value=="")
//       {
//           alert("Please Enter Designation");           
//           document.getElementById("txtDesignation").focus();
//           //document.getElementById("txtDesignation").style.borderColor="Red";
//           return false;
//       }  
       if(document.getElementById("drJobID").value=="0")
       {
           alert("Select Enter Job ID");           
           document.getElementById("drJobID").focus();
           //document.getElementById("txtDesignation").style.borderColor="Red";
           return false;
       } 
//       if(document.getElementById("drProfessional").value=="Select")
//       {
//           alert("Please Select Job Profession");
//           document.getElementById("drProfessional").focus();
//           //document.getElementById("drProfessional").style.borderColor="Red";
//           return false;
//       } 
//       if(document.getElementById("List1")!=null)
//       {           
//           if(document.getElementById("List1").value==" ")
//           {
//               alert("Please Select Required Skill");
//               document.getElementById("List1").focus();
//               //document.getElementById("List1").style.borderColor="Red";
//               return false;
//           }           
//       }
//       if(document.getElementById("drProfessionCat").value=="Select")
//       {
//           alert("Please Select Job Category");
//           document.getElementById("drProfessionCat").focus();
//           //document.getElementById("drProfessionCat").style.borderColor="Red";
//           return false;
//       } 
//       if(document.getElementById("drProfessionSubCat").value=="Select")
//       {
//           alert("Please Select Job Sub Category");
//           document.getElementById("drProfessionSubCat").focus();
//           //document.getElementById("drProfessionSubCat").style.borderColor="Red";
//           return false;
//       }        
//       if(document.getElementById("drJobExp").value=="Select Your Experience")
//       {
//           alert("Please Select Experience Required");
//           document.getElementById("drJobExp").focus();
//           //document.getElementById("drJobExp").style.borderColor="Red";
//           return false;
//       } 
//       if(document.getElementById("lslEduDetails").value=="0")
//       {
//           alert("Please Select Qualification Required");
//           document.getElementById("lslEduDetails").focus();
//           //document.getElementById("lslEduDetails").style.borderColor="Red";
//           return false;
//       }
//       if(document.getElementById("drCountry").value=="India")
//       {
//           if(document.getElementById("drState").value=="0")
//           {
//               alert("Please Select State");
//               document.getElementById("drState").focus();
//               //document.getElementById("drState").style.borderColor="Red";
//               return false;
//           }
//           if(document.getElementById("drdcity").value=="0")
//           {
//               alert("Please Select City");
//               document.getElementById("drdcity").focus();
//               //document.getElementById("drdcity").style.borderColor="Red";
//               return false;
//           }
//       }  
//       if(document.getElementById("drCountry").value=="United States of America")
//       {
//           if(document.getElementById("USAstate").value=="0")
//           {
//               alert("Please Select State");
//               document.getElementById("USAstate").focus();
//               //document.getElementById("USAstate").style.borderColor="Red";
//               return false;
//           }           
//       }
     var examdatecheck=/^((((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|([1-2][0-9]))))[\-\/\s]?\d{2}(([02468][048])|([13579][26])))|(((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))[\-\/\s]?\d{2}(([02468][1235679])|([13579][01345789]))))(\s(((0?[1-9])|(1[0-2]))\:([0-5][0-9])((\s)|(\:([0-5][0-9])\s))([AM|PM|am|pm]{2,2})))?$/;         
     var examdate=document.getElementById("txtExamDate").value;         
     if(examdate=="")
     {
         alert("Please Enter Exam Date");
         document.getElementById("txtExamDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }     
     if(!examdatecheck.test(examdate))
     {
         alert("Exam Date Should Be In mm/dd/yyyy Format");
         document.getElementById("txtExamDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }     
     var datecheck=/^((((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|([1-2][0-9]))))[\-\/\s]?\d{2}(([02468][048])|([13579][26])))|(((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))[\-\/\s]?\d{2}(([02468][1235679])|([13579][01345789]))))(\s(((0?[1-9])|(1[0-2]))\:([0-5][0-9])((\s)|(\:([0-5][0-9])\s))([AM|PM|am|pm]{2,2})))?$/;         
     var date=document.getElementById("txtExamLastDate").value;        
     if(date=="")
     {
         alert("Please Enter Last Date Of Apply");
         document.getElementById("txtExamLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }     
     if(!datecheck.test(date))
     {
         alert("Last Date Of Apply Should Be In mm/dd/yyyy Format");
         document.getElementById("txtExamLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }
//      if(document.getElementById("lblJobType").value=="Hot Job")
//      {
//          if(document.getElementById("minPayType").value=="Type")
//          {
//               alert("Please Enter Minimum Salary Type");
//               document.getElementById("minPayType").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
//          var j=150000;
//          if(document.getElementById("txtMinSalary").value<j)
//          {
//               alert("Minimum Salary Must Be At Least Rs/- 150000 per Annum");
//               document.getElementById("txtMaxSalary").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
//          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
//          {
//               alert("Maximum Salary Must Be Greater Than Minimum Salary");
//               document.getElementById("txtMaxSalary").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
//      }      
//      if(document.getElementById("minPayType").value!="Type")
//      {           
//           if(document.getElementById("txtMinSalary").value=="")
//           {
//               alert("Please Enter Minimum Salary");
//               document.getElementById("txtMinSalary").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//           }
//           if(document.getElementById("minDuration").value=="Duration")
//           {
//               alert("Please Enter Minimum Duration Of Salary");
//               document.getElementById("minDuration").focus();
//               //document.getElementById("minDuration").style.borderColor="Red";
//               return false;
//           }
//           if(document.getElementById("maxPayType").value=="Type")
//           {
//               alert("Please Select Maximum Pay Type");
//               document.getElementById("maxPayType").focus();
//               //document.getElementById("maxPayType").style.borderColor="Red";
//               return false;
//           }
//           if(document.getElementById("txtMaxSalary").value=="")
//           {
//               alert("Please Enter Maximum Salary");
//               document.getElementById("txtMaxSalary").focus();
//               //document.getElementById("txtMaxSalary").style.borderColor="Red";
//               return false;
//           }
//           if(document.getElementById("maxDuration").value=="Duration")
//           {
//               alert("Please Enter Maximum Duration Of Salary");
//               document.getElementById("maxDuration").focus();
//               //document.getElementById("maxDuration").style.borderColor="Red";
//               return false;
//           }
//      }
//     if(document.getElementById("lblJobType").value=="Hot Job")
//      {         
//          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
//          {
//               alert("Maximum Salary Must Be Greater Than Minimum Salary");
//               document.getElementById("txtMaxSalary").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
//      }   
//     var validChars="0123456789";
//     var strChars;
//     var result=true;
//     for(i=0;i<document.Form1.txtMinSalary.value.length && result==true;i++)
//     {
//         strChars=document.Form1.txtMinSalary.value.charAt(i);
//         if(validChars.indexOf(strChars)==-1)
//         {
//             alert("Only Numbers Is Valid In Minimum Salary Field");
//             document.Form1.txtMinSalary.focus();
//             //document.getElementById("txtMinSalary").style.borderColor="Red";
//             result=false;
//             return result;
//         }	         
//     }
//     for(j=0;j<document.Form1.txtMaxSalary.value.length && result==true;j++)
//     {
//         strChars=document.Form1.txtMaxSalary.value.charAt(j);
//         if(validChars.indexOf(strChars)==-1)
//         {
//             alert("Only Numbers Is Valid In Maximum Salary Field");
//             document.Form1.txtMaxSalary.focus();
//             //document.getElementById("txtMaxSalary").style.borderColor="Red";
//             result=false;
//             return result;
//         }	         
//     }	
//     
//     for(k=0;k<document.Form1.txtVacancy.value.length && result==true;k++)
//     {
//         strChars=document.Form1.txtVacancy.value.charAt(k);
//         if(validChars.indexOf(strChars)==-1)
//         {
//             alert("Only Numbers Is Valid In Vacancy Field");
//             document.Form1.txtVacancy.focus();
//             //document.getElementById("txtVacancy").style.borderColor="Red";
//             result=false;
//             return result;
//         }	         
//     }    
//     if(document.getElementById("List1")!=null)
//       {
//          if(document.getElementById("List1").value==" ")
//          {
//             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
//          }
//          else
//          {
//            document.getElementById("hdnSkill").value="false";
//          }
//       }
//       if(document.getElementById("txtSkillOther")!=null)
//       {
//          if(document.getElementById("txtSkillOther").value=="")
//          {
//             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
//          }
//          else
//          {
//            document.getElementById("hdnSkill").value="false";
//          }
//       }   
//     if(examdate=="")
//     {
//         alert("Please Enter Last Date Of Exam");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }
//     if(!examdatecheck.test(examdate))
//     {
//         alert("Last Date For Apply Should Be In dd/mm/yyyy Format");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }      
}

function validate1()
{
      if(document.getElementById("txtCompanyDes").value=="")
      {
           alert("Please Enter Company Description");
           document.getElementById("txtCompanyDes").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }
      if(document.getElementById("txtCompanyDes").value.length>5000)
       {
           alert("Maximum 1000 Characters Are Allowed In \nCompany Description Field");
           document.getElementById("txtCompanyDes").focus();
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtBenefit").value=="")
       {
           alert("Please Enter Company Benefit");
           document.getElementById("txtBenefit").focus();
           ///document.getElementById("txtBenefit").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtBenefit").value.length>5000)
       {
           alert("Maximum 1000 Characters Are Allowed In \nCompany Benefit Field");
           document.getElementById("txtBenefit").focus();
           //document.getElementById("txtBenefit").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtJobDesc").value=="")
       {
           alert("Please Enter Job Description");
           document.getElementById("txtJobDesc").focus();
           //document.getElementById("txtJobDesc").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtJobDesc").value.length>5000)
       {
           alert("Maximum 1000 Characters Are Allowed In \nJob Description Field");
           document.getElementById("txtJobDesc").focus();
           //document.getElementById("txtJobDesc").style.borderColor="Red";
           return false;
       }       
       if(document.getElementById("txtJobName").value=="")
       {
           alert("Please Enter Job Name");
           document.getElementById("txtJobName").focus();
           //document.getElementById("txtJobName").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtDesignation").value=="")
       {
           alert("Please Enter Designation");           
           document.getElementById("txtDesignation").focus();
           //document.getElementById("txtDesignation").style.borderColor="Red";
           return false;
       }  
       if(document.getElementById("drProfessional").value=="-1")
       {
           alert("Please Select Job Profession");
           document.getElementById("drProfessional").focus();
           //document.getElementById("drProfessional").style.borderColor="Red";
           return false;
       }
//        if(document.getElementById("List1").value==" ")
//       {
//           alert("Please Select Skill Required");
//           document.getElementById("List1").focus();
//           //document.getElementById("drProfessional").style.borderColor="Red";
//           return false;
//       }  
//       if(document.getElementById("txtSkillOther")!=null)
//       {           
//           if(document.getElementById("txtSkillOther").value=="")
//           {
//               alert("Please Enter Required Skill");
//               document.getElementById("txtSkillOther").focus();
//               //document.getElementById("List1").style.borderColor="Red";
//               return false;
//           }           
//       }
//       if(document.getElementById("drProfessionCat").value=="Select")
//       {
//           alert("Please Select Job Category");
//           document.getElementById("drProfessionCat").focus();
//           //document.getElementById("drProfessionCat").style.borderColor="Red";
//           return false;
//       } 
//       if(document.getElementById("drProfessionSubCat").value=="Select")
//       {
//           alert("Please Select Job Sub Category");
//           document.getElementById("drProfessionSubCat").focus();
//           //document.getElementById("drProfessionSubCat").style.borderColor="Red";
//           return false;
//       }        
       if(document.getElementById("drJobExp").value=="Min Expeirence")
       {
           alert("Please Select Minimum Experience Required");
           document.getElementById("drJobExp").focus();
           //document.getElementById("drJobExp").style.borderColor="Red";
           return false;
       } 
       if(document.getElementById("drJobExp1").value=="Max Experience")
       {
           alert("Please Select Maximum Experience Required");
           document.getElementById("drJobExp1").focus();
           //document.getElementById("drJobExp").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("drJobExp").value!="Min Exp")
	{         
	   if(document.getElementById("drJobExp1").value=="Max Exp")
	   {	   
		    alert("Select Maximum Experience");
		    document.getElementById("drJobExp1").focus();
		    return false;			
	   }	   
    }   
    if(document.getElementById("drJobExp1").value!="Max Exp")
	{         
	   if(document.getElementById("drJobExp").value=="Min Exp")
	   {	   
		    alert("Select Minimum Experience");
		    document.getElementById("drJobExp").focus();
		    return false;			
	   }	   
    }
    if(document.getElementById("drJobExp").value!="Min Exp" && document.getElementById("drJobExp1").value!="Max Exp") 
    {
        if(parseInt(document.getElementById("drJobExp1").value)<=parseInt(document.getElementById("drJobExp").value))
	    {         
	            alert("Maximum Experience Must Be Greater Than Minimum Experience");
		        document.getElementById("drJobExp").focus();
		        return false;			   
        } 
    } 
       if(document.getElementById("lslEduDetails").value=="0")
       {
           alert("Please Select Qualification Required");
           document.getElementById("lslEduDetails").focus();
           //document.getElementById("lslEduDetails").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("drCountry").value==" ")
       {
           alert("Please Select Country");
           document.getElementById("drCountry").focus();
           //document.getElementById("drState").style.borderColor="Red";
           return false;
       }       
       if(document.getElementById("drState").value=="" || document.getElementById("drState").value==" ")
       {
           alert("Please Select State");
           document.getElementById("drState").focus();
           //document.getElementById("drState").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("drDistrict").value=="" || document.getElementById("drDistrict").value==" ")
       {
           alert("Please Select District");
           document.getElementById("drDistrict").focus();
           //document.getElementById("drdcity").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("drdcity").value=="" || document.getElementById("drdcity").value==" ")
       {
           alert("Please Select City");
           document.getElementById("drdcity").focus();
           //document.getElementById("drdcity").style.borderColor="Red";
           return false;
       }
     var datecheck=/^((((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|([1-2][0-9]))))[\-\/\s]?\d{2}(([02468][048])|([13579][26])))|(((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))[\-\/\s]?\d{2}(([02468][1235679])|([13579][01345789]))))(\s(((0?[1-9])|(1[0-2]))\:([0-5][0-9])((\s)|(\:([0-5][0-9])\s))([AM|PM|am|pm]{2,2})))?$/;    
     //var datecheck=/^(([0-2]?\d{1})|([3][0,1]{1}))\/(([0]?\d{1})|([1]{1}[0-2]))\/(([1]{1}[9]{1}[7-9]{1}\d{1})|([2-9]{1}\d{3}))$/;
     var examdatecheck=/^(([0-2]?\d{1})|([3][0,1]{1}))\/(([0]?\d{1})|([1]{1}[0-2]))\/(([1]{1}[9]{1}[7-9]{1}\d{1})|([2-9]{1}\d{3}))$/;
     var date=document.getElementById("txtLastDate").value;
     //var examdate=document.getElementById("txtExamLastDate").value;     
     if(date=="")
     {
         alert("Please Enter Last Date Of Apply");
         document.getElementById("txtLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }     
     if(!datecheck.test(date))
     {
         alert("Last Date Of Apply Should Be In mm/dd/yyyy Format");
         document.getElementById("txtLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }
      if(document.getElementById("lblJobType").value=="Hot Job")
      {
          if(document.getElementById("minPayType").value=="Type")
          {
               alert("Please Enter Minimum Salary Type");
               document.getElementById("minPayType").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
          }
          var j=150000;
          if(document.getElementById("txtMinSalary").value<j)
          {
               alert("Minimum Salary Must Be At Least Rs/- 150000 per Annum");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
          }
//          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
//          {
//               alert("Maximum Salary Must Be Greater Than Minimum Salary");
//               document.getElementById("txtMaxSalary").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
      }      
      if(document.getElementById("minPayType").value!="Type")
      {           
           if(document.getElementById("txtMinSalary").value=="")
           {
               alert("Please Enter Minimum Salary");
               document.getElementById("txtMinSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("minDuration").value=="Duration")
           {
               alert("Please Enter Minimum Duration Of Salary");
               document.getElementById("minDuration").focus();
               //document.getElementById("minDuration").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("maxPayType").value=="Type")
           {
               alert("Please Select Maximum Pay Type");
               document.getElementById("maxPayType").focus();
               //document.getElementById("maxPayType").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("txtMaxSalary").value=="")
           {
               alert("Please Enter Maximum Salary");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMaxSalary").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("maxDuration").value=="Duration")
           {
               alert("Please Enter Maximum Duration Of Salary");
               document.getElementById("maxDuration").focus();
               //document.getElementById("maxDuration").style.borderColor="Red";
               return false;
           }
      }
     if(document.getElementById("lblJobType").value=="Hot Job")
      {         
          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
          {
               alert("Maximum Salary Must Be Greater Than Minimum Salary");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
          }
      }   
     var validChars="0123456789";
     var strChars;
     var result=true;
     for(i=0;i<document.Form1.txtMinSalary.value.length && result==true;i++)
     {
         strChars=document.Form1.txtMinSalary.value.charAt(i);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Minimum Salary Field");
             document.Form1.txtMinSalary.focus();
             //document.getElementById("txtMinSalary").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }
     for(j=0;j<document.Form1.txtMaxSalary.value.length && result==true;j++)
     {
         strChars=document.Form1.txtMaxSalary.value.charAt(j);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Maximum Salary Field");
             document.Form1.txtMaxSalary.focus();
             //document.getElementById("txtMaxSalary").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }	
     
     for(k=0;k<document.Form1.txtVacancy.value.length && result==true;k++)
     {
         strChars=document.Form1.txtVacancy.value.charAt(k);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Vacancy Field");
             document.Form1.txtVacancy.focus();
             //document.getElementById("txtVacancy").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }    
       if(document.getElementById("List1")!=null)
       {
          if(document.getElementById("List1").value=="-1")
          {
             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
          }
          else
          {
            document.getElementById("hdnSkill").value="false";
          }
       }
       if(document.getElementById("txtSkillOther")!=null)
       {
          if(document.getElementById("txtSkillOther").value=="")
          {
             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
          }
          else
          {
            document.getElementById("hdnSkill").value="false";
          }
       }   
//     if(examdate=="")
//     {
//         alert("Please Enter Last Date Of Exam");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }
//     if(!examdatecheck.test(examdate))
//     {
//         alert("Last Date For Apply Should Be In dd/mm/yyyy Format");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }      
                     	               	    
}

function TempJobValidate()
{
      if(document.getElementById("txtCompanyName").value=="")
      {
           alert("Please Enter Company Name");
           document.getElementById("txtCompanyName").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }
      
      if(document.getElementById("Txt_com_web").value=="")
      {
           alert("Please Enter Company Website");
           document.getElementById("Txt_com_web").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      } 
      if(document.getElementById("txt_com_add").value=="")
      {
           alert("Please Enter Company Address");
           document.getElementById("txt_com_add").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }         
      if(document.getElementById("txt_com_ph").value=="")
      {
           alert("Please Enter Company Phone Number");
           document.getElementById("txt_com_ph").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      } 
     var validChars="0123456789";
     var strChars;
     var result=true;
     for(i=0;i<document.Form1.txt_com_ph.value.length && result==true;i++)
     {
         strChars=document.Form1.txt_com_ph.value.charAt(i);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Phone Number Is Not Valid");
             document.Form1.txt_com_ph.focus();
             //document.getElementById("txtMinSalary").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }
      if(document.getElementById("txtCompanyDes").value=="")
      {
           alert("Please Enter Company Description");
           document.getElementById("txtCompanyDes").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }
      if(document.getElementById("txtCompanyDes").value.length>5000)
       {
           alert("Maximum 5000 Characters Are Allowed In \nCompany Description Field");
           document.getElementById("txtCompanyDes").focus();
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtBenefit").value=="")
       {
           alert("Please Enter Company Benefit");
           document.getElementById("txtBenefit").focus();
           ///document.getElementById("txtBenefit").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtBenefit").value.length>5000)
       {
           alert("Maximum 5000 Characters Are Allowed In \nCompany Benefit Field");
           document.getElementById("txtBenefit").focus();
           //document.getElementById("txtBenefit").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtJobDesc").value=="")
       {
           alert("Please Enter Job Description");
           document.getElementById("txtJobDesc").focus();
           //document.getElementById("txtJobDesc").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtJobDesc").value.length>5000)
       {
           alert("Maximum 5000 Characters Are Allowed In \nJob Description Field");
           document.getElementById("txtJobDesc").focus();
           //document.getElementById("txtJobDesc").style.borderColor="Red";
           return false;
       }       
       if(document.getElementById("txtJobName").value=="")
       {
           alert("Please Enter Job Name");
           document.getElementById("txtJobName").focus();
           //document.getElementById("txtJobName").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtDesignation").value=="")
       {
           alert("Please Enter Designation");           
           document.getElementById("txtDesignation").focus();
           //document.getElementById("txtDesignation").style.borderColor="Red";
           return false;
       }  
       if(document.getElementById("txtJobCode").value=="")
       {
           alert("Please Enter JobID");           
           document.getElementById("txtJobCode").focus();
           //document.getElementById("txtDesignation").style.borderColor="Red";
           return false;
       }        
       if(document.getElementById("drProfessional").value=="Select")
       {
           alert("Please Select Job Profession");
           document.getElementById("drProfessional").focus();
           //document.getElementById("drProfessional").style.borderColor="Red";
           return false;
       } 
//       if(document.getElementById("List1")!=null)
//       {           
//           if(document.getElementById("List1").value==" ")
//           {
//               alert("Please Select Required Skill");
//               document.getElementById("List1").focus();
//               //document.getElementById("List1").style.borderColor="Red";
//               return false;
//           }           
//       }
       if(document.getElementById("drProfessionCat").value=="Select")
       {
           alert("Please Select Job Category");
           document.getElementById("drProfessionCat").focus();
           //document.getElementById("drProfessionCat").style.borderColor="Red";
           return false;
       } 
       if(document.getElementById("drProfessionSubCat").value=="Select")
       {
           alert("Please Select Job Sub Category");
           document.getElementById("drProfessionSubCat").focus();
           //document.getElementById("drProfessionSubCat").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("drJobExp").value=="Min Experience")
       {
           alert("Please Select Minimum Experience Required");
           document.getElementById("drJobExp").focus();
           //document.getElementById("drJobExp").style.borderColor="Red";
           return false;
       } 
       if(document.getElementById("drJobExp1").value=="Max Experience")
       {
           alert("Please Select Maximum Experience Required");
           document.getElementById("drJobExp1").focus();
           //document.getElementById("drJobExp").style.borderColor="Red";
           return false;
       }
       
       if(document.getElementById("lstbx_edu_details").value=="0")
       {
           alert("Please Select Qualification Required");
           document.getElementById("lstbx_edu_details").focus();
           //document.getElementById("lslEduDetails").style.borderColor="Red";
           return false;
       }
      if(document.getElementById("drCountry").value=="0")
       {
            alert("Please Select Country");
            document.getElementById("drCountry").focus();
            return false;
       }
      if(document.getElementById("drCountry").value=="India")
       {
           if(document.getElementById("drState").value=="0")
           {
               alert("Please Select State");
               document.getElementById("drState").focus();
               //document.getElementById("drState").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("drdcity").value=="0")
           {
               alert("Please Select City");
               document.getElementById("drdcity").focus();
               //document.getElementById("drdcity").style.borderColor="Red";
               return false;
           }
       }  
       if(document.getElementById("drCountry").value=="United States of America")
       {
           if(document.getElementById("USAstate").value==" ")
           {
               alert("Please Select State");
               document.getElementById("USAstate").focus();
               //document.getElementById("USAstate").style.borderColor="Red";
               return false;
           }           
       }
      var datecheck=/^((((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|([1-2][0-9]))))[\-\/\s]?\d{2}(([02468][048])|([13579][26])))|(((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))[\-\/\s]?\d{2}(([02468][1235679])|([13579][01345789]))))(\s(((0?[1-9])|(1[0-2]))\:([0-5][0-9])((\s)|(\:([0-5][0-9])\s))([AM|PM|am|pm]{2,2})))?$/;    
     //var datecheck=/^(([0-2]?\d{1})|([3][0,1]{1}))\/(([0]?\d{1})|([1]{1}[0-2]))\/(([1]{1}[9]{1}[7-9]{1}\d{1})|([2-9]{1}\d{3}))$/;
     var examdatecheck=/^(([0-2]?\d{1})|([3][0,1]{1}))\/(([0]?\d{1})|([1]{1}[0-2]))\/(([1]{1}[9]{1}[7-9]{1}\d{1})|([2-9]{1}\d{3}))$/;
     var date=document.getElementById("txtLastDate").value;
     //var examdate=document.getElementById("txtExamLastDate").value;     
     if(date=="")
     {
         alert("Please Enter Last Date Of Apply");
         document.getElementById("txtLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }     
     if(!datecheck.test(date))
     {
         alert("Last Date Of Apply Should Be In mm/dd/yyyy Format");
         document.getElementById("txtLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }
// if(document.getElementById("lblJobType").value=="Hot Job")
//      {
//          if(document.getElementById("minPayType").value=="Type")
//          {
//               alert("Please Enter Minimum Salary Type");
//               document.getElementById("minPayType").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
//          var j=150000;
//          if(document.getElementById("txtMinSalary").value<j)
//          {
//               alert("Minimum Salary Must Be At Least Rs/- 150000 per Annum");
//               document.getElementById("txtMaxSalary").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
////          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
////          {
////               alert("Maximum Salary Must Be Greater Than Minimum Salary");
////               document.getElementById("txtMaxSalary").focus();
////               //document.getElementById("txtMinSalary").style.borderColor="Red";
////               return false;
////          }
//      }      
              if(document.getElementById("minPayType").value=="Type")
              {     
                alert("Please Select Minimum Pay Type");
                document.getElementById("minPayType").focus();
                return false;
              }      
           if(document.getElementById("txtMinSalary").value=="")
           {
               alert("Please Enter Minimum Salary");
               document.getElementById("txtMinSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("minDuration").value=="Select Duration")
           {
               alert("Please Enter Minimum Duration Of Salary");
               document.getElementById("minDuration").focus();
               //document.getElementById("minDuration").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("maxPayType").value=="Type")
           {
               alert("Please Select Maximum Pay Type");
               document.getElementById("maxPayType").focus();
               //document.getElementById("maxPayType").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("txtMaxSalary").value=="")
           {
               alert("Please Enter Maximum Salary");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMaxSalary").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("maxDuration").value=="Duration")
           {
               alert("Please Enter Maximum Duration Of Salary");
               document.getElementById("maxDuration").focus();
               //document.getElementById("maxDuration").style.borderColor="Red";
               return false;
           }
      
     if(document.getElementById("lblJobType").value=="Hot Job")
      {         
          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
          {
               alert("Maximum Salary Must Be Greater Than Minimum Salary");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
          }
      }   
     var validChars="0123456789";
     var strChars;
     var result=true;
     for(i=0;i<document.Form1.txtMinSalary.value.length && result==true;i++)
     {
         strChars=document.Form1.txtMinSalary.value.charAt(i);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Minimum Salary Field");
             document.Form1.txtMinSalary.focus();
             //document.getElementById("txtMinSalary").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }
     for(j=0;j<document.Form1.txtMaxSalary.value.length && result==true;j++)
     {
         strChars=document.Form1.txtMaxSalary.value.charAt(j);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Maximum Salary Field");
             document.Form1.txtMaxSalary.focus();
             //document.getElementById("txtMaxSalary").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }	
     
     for(k=0;k<document.Form1.txtVacancy.value.length && result==true;k++)
     {
         strChars=document.Form1.txtVacancy.value.charAt(k);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Vacancy Field");
             document.Form1.txtVacancy.focus();
             //document.getElementById("txtVacancy").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }    
//     if(document.getElementById("List1")!=null)
//       {
//          if(document.getElementById("List1").value==" ")
//          {
//             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
//          }
//          else
//          {
//            document.getElementById("hdnSkill").value="false";
//          }
//       }
//       if(document.getElementById("txtSkillOther")!=null)
//       {
//          if(document.getElementById("txtSkillOther").value=="")
//          {
//             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
//          }
//          else
//          {
//            document.getElementById("hdnSkill").value="false";
//          }
//       }   
//     if(examdate=="")
//     {
//         alert("Please Enter Last Date Of Exam");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }
//     if(!examdatecheck.test(examdate))
//     {
//         alert("Last Date For Apply Should Be In dd/mm/yyyy Format");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }      
                     	               	    
}


function UpdateValidate()
{
      if(document.getElementById("txt_ComWeb").value=="")
      {
           alert("Please Enter Company Website");
           document.getElementById("txt_ComWeb").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }
      if(document.getElementById("txt_ComAdd").value=="")
      {
           alert("Please Enter Company Address");
           document.getElementById("txt_ComAdd").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }
      if(document.getElementById("txt_ComPh").value=="")
      {
           alert("Please Enter Company Phone No");
           document.getElementById("txt_ComPh").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }
      if(document.getElementById("txtCompanyDes").value=="")
      {
           alert("Please Enter Company Description");
           document.getElementById("txtCompanyDes").focus();          
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
      }
      if(document.getElementById("txtCompanyDes").value.length>5000)
       {
           alert("Maximum 1000 Characters Are Allowed In \nCompany Description Field");
           document.getElementById("txtCompanyDes").focus();
           //document.getElementById("txtCompanyDes").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtBenefit").value=="")
       {
           alert("Please Enter Company Benefit");
           document.getElementById("txtBenefit").focus();
           ///document.getElementById("txtBenefit").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtBenefit").value.length>5000)
       {
           alert("Maximum 1000 Characters Are Allowed In \nCompany Benefit Field");
           document.getElementById("txtBenefit").focus();
           //document.getElementById("txtBenefit").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtJobDesc").value=="")
       {
           alert("Please Enter Job Description");
           document.getElementById("txtJobDesc").focus();
           //document.getElementById("txtJobDesc").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtJobDesc").value.length>5000)
       {
           alert("Maximum 1000 Characters Are Allowed In \nJob Description Field");
           document.getElementById("txtJobDesc").focus();
           //document.getElementById("txtJobDesc").style.borderColor="Red";
           return false;
       }       
       if(document.getElementById("txtJobName").value=="")
       {
           alert("Please Enter Job Name");
           document.getElementById("txtJobName").focus();
           //document.getElementById("txtJobName").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("txtDesignation").value=="")
       {
           alert("Please Enter Designation");           
           document.getElementById("txtDesignation").focus();
           //document.getElementById("txtDesignation").style.borderColor="Red";
           return false;
       }  
       if(document.getElementById("drProfessional").value=="-1")
       {
           alert("Please Select Job Profession");
           document.getElementById("drProfessional").focus();
           //document.getElementById("drProfessional").style.borderColor="Red";
           return false;
       } 
//       if(document.getElementById("List1")!=null)
//       {           
//           if(document.getElementById("List1").value==" ")
//           {
//               alert("Please Select Required Skill");
//               document.getElementById("List1").focus();
//               //document.getElementById("List1").style.borderColor="Red";
//               return false;
//           }           
//       }
//       if(document.getElementById("drProfessionCat").value=="Select")
//       {
//           alert("Please Select Job Category");
//           document.getElementById("drProfessionCat").focus();
//           //document.getElementById("drProfessionCat").style.borderColor="Red";
//           return false;
//       } 
//       if(document.getElementById("drProfessionSubCat").value=="Select")
//       {
//           alert("Please Select Job Sub Category");
//           document.getElementById("drProfessionSubCat").focus();
//           //document.getElementById("drProfessionSubCat").style.borderColor="Red";
//           return false;
//       }        
       if(document.getElementById("drJobExp").value=="Min Experience")
       {
           alert("Please Select Minimum Experience Required");
           document.getElementById("drJobExp").focus();
           //document.getElementById("drJobExp").style.borderColor="Red";
           return false;
       } 
       if(document.getElementById("drJobExp1").value=="Max Experience")
       {
           alert("Please Select Maximum Experience Required");
           document.getElementById("drJobExp1").focus();
           //document.getElementById("drJobExp").style.borderColor="Red";
           return false;
       } 
       if(document.getElementById("lbl_eduQual").value=="")
       {
           alert("Please Select Qualification Required");
           document.getElementById("lslEduDetails").focus();
           //document.getElementById("lslEduDetails").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("drCountry").value==" ")
       {
           alert("Please Select Country");
           document.getElementById("drCountry").focus();            
           return false;
       }       
       if(document.getElementById("lbl_state").value=="")
       {
           alert("Please Select State.\nClick On Change State.");
           //document.getElementById("drState").focus();
           //document.getElementById("drState").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("lbl_District").value=="")
       {
           alert("Please Select District.\nClick On Change District.");
           //document.getElementById("drDistrict").focus();
           //document.getElementById("drdcity").style.borderColor="Red";
           return false;
       }
       if(document.getElementById("lbl_city").value=="")
       {
           alert("Please Select City.\nClick On Change City.");
           //document.getElementById("drdcity").focus();
           //document.getElementById("drdcity").style.borderColor="Red";
           return false;
       }
     var datecheck=/^((((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|([1-2][0-9]))))[\-\/\s]?\d{2}(([02468][048])|([13579][26])))|(((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))[\-\/\s]?\d{2}(([02468][1235679])|([13579][01345789]))))(\s(((0?[1-9])|(1[0-2]))\:([0-5][0-9])((\s)|(\:([0-5][0-9])\s))([AM|PM|am|pm]{2,2})))?$/;
     //var datecheck=/^(([0-2]?\d{1})|([3][0,1]{1}))\/(([0]?\d{1})|([1]{1}[0-2]))\/(([1]{1}[9]{1}[7-9]{1}\d{1})|([2-9]{1}\d{3}))$/;
     var examdatecheck=/^(([0-2]?\d{1})|([3][0,1]{1}))\/(([0]?\d{1})|([1]{1}[0-2]))\/(([1]{1}[9]{1}[7-9]{1}\d{1})|([2-9]{1}\d{3}))$/;
     var date=document.getElementById("txtLastDate").value;
     //alert(date);
     //var examdate=document.getElementById("txtExamLastDate").value;     
     if(date=="")
     {
         alert("Please Enter Last Date Of Apply");
         document.getElementById("txtLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }     
     if(!datecheck.test(date))
     {
         alert("Last Date Of Apply Should Be In mm/dd/yyyy Format");
         document.getElementById("txtLastDate").focus();
         //document.getElementById("txtLastDate").style.borderColor="Red";
         return false;
     }
      if(document.getElementById("lblJobType").value=="Hot Job")
      {
          if(document.getElementById("minPayType").value=="Type")
          {
               alert("Please Enter Minimum Salary Type");
               document.getElementById("minPayType").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
          }
          var j=150000;
          if(document.getElementById("txtMinSalary").value<j)
          {
               alert("Minimum Salary Must Be At Least Rs/- 150000 per Annum");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
          }
//          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
//          {
//               alert("Maximum Salary Must Be Greater Than Minimum Salary");
//               document.getElementById("txtMaxSalary").focus();
//               //document.getElementById("txtMinSalary").style.borderColor="Red";
//               return false;
//          }
      }      
      if(document.getElementById("minPayType").value!="Type")
      {           
           if(document.getElementById("txtMinSalary").value=="")
           {
               alert("Please Enter Minimum Salary");
               document.getElementById("txtMinSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("minDuration").value=="Duration")
           {
               alert("Please Enter Minimum Duration Of Salary");
               document.getElementById("minDuration").focus();
               //document.getElementById("minDuration").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("maxPayType").value=="Type")
           {
               alert("Please Select Maximum Pay Type");
               document.getElementById("maxPayType").focus();
               //document.getElementById("maxPayType").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("txtMaxSalary").value=="")
           {
               alert("Please Enter Maximum Salary");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMaxSalary").style.borderColor="Red";
               return false;
           }
           if(document.getElementById("maxDuration").value=="Duration")
           {
               alert("Please Enter Maximum Duration Of Salary");
               document.getElementById("maxDuration").focus();
               //document.getElementById("maxDuration").style.borderColor="Red";
               return false;
           }
      }
     if(document.getElementById("lblJobType").value=="Hot Job")
      {         
          if(document.getElementById("txtMinSalary").value>=document.getElementById("txtMaxSalary").value)
          {
               alert("Maximum Salary Must Be Greater Than Minimum Salary");
               document.getElementById("txtMaxSalary").focus();
               //document.getElementById("txtMinSalary").style.borderColor="Red";
               return false;
          }
      }   
     var validChars="0123456789";
     var strChars;
     var result=true;
     for(i=0;i<document.Form1.txtMinSalary.value.length && result==true;i++)
     {
         strChars=document.Form1.txtMinSalary.value.charAt(i);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Minimum Salary Field");
             document.Form1.txtMinSalary.focus();
             //document.getElementById("txtMinSalary").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }
     for(j=0;j<document.Form1.txtMaxSalary.value.length && result==true;j++)
     {
         strChars=document.Form1.txtMaxSalary.value.charAt(j);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Maximum Salary Field");
             document.Form1.txtMaxSalary.focus();
             //document.getElementById("txtMaxSalary").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }	
     
     for(k=0;k<document.Form1.txtVacancy.value.length && result==true;k++)
     {
         strChars=document.Form1.txtVacancy.value.charAt(k);
         if(validChars.indexOf(strChars)==-1)
         {
             alert("Only Numbers Is Valid In Vacancy Field");
             document.Form1.txtVacancy.focus();
             //document.getElementById("txtVacancy").style.borderColor="Red";
             result=false;
             return result;
         }	         
     }    
//     if(document.getElementById("List1")!=null)
//       {
//          if(document.getElementById("List1").value=="")
//          {
//             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
//          }
//          else
//          {
//            document.getElementById("hdnSkill").value="false";
//          }
//       }
//       if(document.getElementById("txtSkillOther")!=null)
//       {
//          if(document.getElementById("txtSkillOther").value=="")
//          {
//             document.getElementById("hdnSkill").value=window.confirm("Skill Not Mentioned.If You Want To Mention Skill Click On OK\n Otherwise Click On Cancel");        
//          }
//          else
//          {
//            document.getElementById("hdnSkill").value="false";
//          }
//       }   
//     if(examdate=="")
//     {
//         alert("Please Enter Last Date Of Exam");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }
//     if(!examdatecheck.test(examdate))
//     {
//         alert("Last Date For Apply Should Be In dd/mm/yyyy Format");
//         document.getElementById("txtExamLastDate").focus();
//         return false;
//     }      
                     	               	    
}
