// JScript File

function ValidateForm()
{	 
	   if (document.form.name.value=="")
       {
                 alert("Name Field can not be blank...!!!");
                 document.form.name.focus()
                 document.form.name.value='';
                 return false
       } 
       
	   if (document.form.designation.value=="")
       {
                 alert("Designation Field can not be blank...!!!");
                 document.form.designation.focus()
                 document.form.designation.value='';
                 return false
       } 
	   if (document.form.Company_Name.value=="")
       {
                 alert("Company_Name Field can not be blank...!!!");
                 document.form.Company_Name.focus()
                 document.form.Company_Name.value='';
                 return false
       } 
	   if (document.form.address.value=="")
       {
                 alert("Address Field can not be blank...!!!");
                 document.form.address.focus()
                 document.form.address.value='';
                 return false
       } 
	   if (document.form.City.value=="")
       {
                 alert("City Field can not be blank...!!!");
                 document.form.City.focus()
                 document.form.City.value='';
                 return false
       } 
	   if (document.form.country.value=="")
       {
                 alert("Country Field can not be blank...!!!");
                 document.form.country.focus()
                 document.form.country.value='';
                 return false
       } 
	   if (document.form.mobile.value=="")
       {
                 alert("Mobile Field can not be blank...!!!");
                 document.form.mobile.focus()
                 document.form.mobile.value='';
                 return false
       } 
	   if (document.form.phone.value=="")
       {
                 alert("Phone Field can not be blank...!!!");
                 document.form.phone.focus()
                 document.form.phone.value='';
                 return false
       } 
	   if (document.form.fax.value=="")
       {
                 alert("Fax Field can not be blank...!!!");
                 document.form.fax.focus()
                 document.form.fax.value='';
                 return false
       } 
	   
	   var tempEmail= document.form.mail.value;
	   var exclude=/[^@\-\.\w]|^[_@\.\-]|[\._\-]{2}|[@\.]{2}|(@)[^@]*\1/;
	   var check=/@[\w\-]+\./;
	   var checkend=/\.[a-zA-Z]{2,3}$/;
       if (document.form.mail.value==""||document.form.mail.value!="")
       {
           if (tempEmail.search(exclude)!=-1||tempEmail.search(check)==-1||tempEmail.search(checkend)==-1)
	           {
		          alert("Input valid your Email Address again?");
		          document.form.mail.focus();
		          document.form.mail.value='';
		           return false
	           }
       } 
	    
	   if (document.form.enquiry.value=="")
       {
                 alert("Comments Field can not be blank...!!!");
                 document.form.enquiry.focus()
                 document.form.enquiry.value='';
                 return false
       } 
     		
		 return true
 }
 
 function alpha(e) // Enter Only Letter
	{
     var k;
     document.all ? k = e.keyCode : k = e.which;
     return ((k > 64 && k < 91) || (k > 96 && k < 123 )|| k <= 32 || k == 8 );
    }
    
 function isNumberKey(evt) // Enter Only Letter
	{
      var charCode = (evt.which) ? evt.which : event.keyCode
      if (charCode > 31 && (charCode < 43 || charCode > 57))
      return false;
      return true;
   }