function checkvalid()
{

	var Salutation = document.frmadd.vSalutation;
	
	if(Trim(Salutation.options[Salutation.selectedIndex].value) == "")

	{

		alert("Please Select Salutation ");

		Salutation.focus();

		return false;

	}
	
	var Fname = Trim(document.frmadd.vFirstName.value);

	if(Fname.length < 1)

	{

		alert("Please Enter First Name");

		document.frmadd.vFirstName.value = "";

		document.frmadd.vFirstName.focus();

		return false;

	}
	
	var Lname = Trim(document.frmadd.vLastName.value);

	if(Lname.length < 1)

	{

		alert("Please Enter Last Name");

		document.frmadd.vLastName.value = "";

		document.frmadd.vLastName.focus();

		return false;

	}

	if(!isValidEmail(document.frmadd.vEmail.value))

	{

		document.frmadd.vEmail.value = "";

		document.frmadd.vEmail.focus();

		return false;

	}
	
	var Phone = Trim(document.frmadd.vPhone.value);

	if(Phone.length < 1)

	{

		alert("Please Enter Phone Number");

		document.frmadd.vPhone.value = "";

		document.frmadd.vPhone.focus();

		return false;

	}
	
	if(Phone.length > 1 && isNaN(Phone))

	{

		alert("Please Enter Valid Phone Number");

		document.frmadd.vPhone.value = "";

		document.frmadd.vPhone.focus();

		return false;

	}
	

	/*

	var company = Trim(document.frmadd.vCompany.value);

	if(company.length < 1)

	{

		alert("Please Enter Company Name");

		document.frmadd.vCompany.value = "";

		document.frmadd.vCompany.focus();

		return false;

	} 

	

	if(document.frmadd.vAddress.value == "")

	{

			alert("Please Enter Address");

			document.frmadd.vAddress.value = "";

			document.frmadd.vAddress.focus();

			return false;

	}	

	var city = Trim(document.frmadd.vCity.value)

	if(city.length < 1)

	{

		alert("Please Enter City");

		document.frmadd.vCity.value = "";

		document.frmadd.vCity.focus();

		return false;

	}

	if(document.frmadd.vState.value.length < 1)

	{

		alert("Please Enter State");

		document.frmadd.vState.focus();

		return false;

	}

	if(document.frmadd.vZip.value.length < 1)

	{

		alert("Please Enter Zip");

		document.frmadd.vZip.focus();

		return false;

	}

	else if(!number(document.frmadd.vZip.value,document.frmadd.vZip.value.length))

	{

		alert("Please Enter Valid Zip");

		document.frmadd.vZip.value = "";

		document.frmadd.vZip.focus();

		return false;

	}

	var Country = document.frmadd.vCountry;
	
	if(Trim(Country.options[Country.selectedIndex].value) == "")

	{

		alert("Please Select Country");

		Country.focus();

		return false;

	}
	
	var UserName = Trim(document.frmadd.vUsername.value)

	if(UserName.length < 1)

	{

		alert("Please Enter User Name");

		document.frmadd.vUsername.value = "";

		document.frmadd.vUsername.focus();

		return false;

	}

	var Password = Trim(document.frmadd.vPassword.value)

	if(Password.length < 1)

	{

		alert("Please Enter Password");

		document.frmadd.vPassword.value = "";

		document.frmadd.vPassword.focus();

		return false;

	}
	
	var CPassword = Trim(document.frmadd.vCPassword.value)
	
	if(!document.frmadd.vPassword.value == document.frmadd.vCPassword.value)
	{
		
		alert("Both Password Should Match");
		
		document.frmadd.vCPassword.focus();
		
		return false;
		
	}*/

}







function checkvalid1()

{

	var Salutation = document.frmadd.vFirstName;
	
	if(Salutation.options[Salutation.selectedIndex].value = "")

	{

		alert("Please Select Salutation ");

		Salutation.focus();

		return false;

	}
	
	
	var Fname = Trim(document.frmadd.vFirstName.value);

	if(Fname.length < 1)

	{

		alert("Please Enter First Name");

		document.frmadd.vFirstName.value = "";

		document.frmadd.vFirstName.focus();

		return false;

	}
	
	var Lname = Trim(document.frmadd.vLastName.value);

	if(Lname.length < 1)

	{

		alert("Please Enter Last Name");

		document.frmadd.vLastName.value = "";

		document.frmadd.vLastName.focus();

		return false;

	}
	
	if(!isValidEmail(document.frmadd.vEmail.value))

	{

		document.frmadd.vEmail.value = "";

		document.frmadd.vEmail.focus();

		return false;

	}

	/*

	var company = Trim(document.frmadd.vCompany.value);

	if(company.length < 1)

	{

		alert("Please Enter Company Name");

		document.frmadd.vCompany.value = "";

		document.frmadd.vCompany.focus();

		return false;

	} 

	*/

	if(document.frmadd.vAddress.value == "")

	{

			alert("Please Enter Address");

			document.frmadd.vAddress.value = "";

			document.frmadd.vAddress.focus();

			return false;

	}	

	var city = Trim(document.frmadd.vCity.value)

	if(city.length < 1)

	{

		alert("Please Enter City");

		document.frmadd.vCity.value = "";

		document.frmadd.vCity.focus();

		return false;

	}

	if(document.frmadd.vState.value.length < 1)

	{

		alert("Please Enter State");

		document.frmadd.vState.focus();

		return false;

	}

	if(document.frmadd.vZip.value.length < 1)

	{

		alert("Please Enter Zip");

		document.frmadd.vZip.focus();

		return false;

	}

	else if(!number(document.frmadd.vZip.value,document.frmadd.vZip.value.length))

	{

		alert("Please Enter Valid Zip");

		document.frmadd.vZip.value = "";

		document.frmadd.vZip.focus();

		return false;

	}

	if(document.frmadd.vUsername.value == "")

	{

			alert("Please Enter Username");

			document.frmadd.vUsername.value = "";

			document.frmadd.vUsername.focus();

			return false;

	}	if(document.frmadd.vPassword.value == "")

	{

			alert("Please Enter password");

			document.frmadd.vPassword.value = "";

			document.frmadd.vPassword.focus();

			return false;

	}	



}

