	var has_focus;
	var object_to_focus;
	
	function ValidateForm() {
		try
		{
		
			var error = "";
			var flag = false;
			var temp = "";	
			
			has_focus = false;
			object_to_focus = null;
			
			HideAllErrors();	
				
			var e_FirstName = $('e_FirstName');
			var e_LastName = $('e_LastName');
			var e_Email = $('e_Email');
			var e_Comments = $('e_Comments');
			
			var FirstName = $('txtFirstName');
			var LastName = $('txtLastName');
			var Email = $('txtEmail');
			var Phone = $('txtPhone');
			var HearAboutUs = $('ddlHearAboutUs');
			var Comments = $('txtComments');			
			
			if(FirstName.value.trim() == "")
			{
				error = AppendError(error, "Enter a First Name.");
				CheckFocus(FirstName);
				e_FirstName.toggle();				
			}
			
			if(LastName.value.trim() == "")
			{
				error = AppendError(error, "Enter a Last Name.");
				CheckFocus(LastName);
				e_LastName.toggle();	
			}
			
			if(Email.value.trim() == "" || Email.value.IsEmail() == false)
			{
				error = AppendError(error, "Enter an Valid Email Address.");
				CheckFocus(Email);
				e_Email.toggle();				
			}
			
			if(Comments.value.trim() == "")
			{
				error = AppendError(error, "Enter a Comment.");
				CheckFocus(Comments);
				e_Comments.toggle();		
			}
			
			
			if(error != "")
			{
				alert(error);
				AfterMessage();
				$('javascript_check').value = "1";
				return false;
			}
			
			return true;
		}
		catch(e)
		{
			alert(e);
			return false;
		}
	}
