function Validator(theForm)
{
	if (theForm.FirstName.value == "")
	{
		alert("Please enter first name.");
		theForm.FirstName.focus();
		return (false);
	}
  
	var myRegExpr = new RegExp("^([A-Z]+[ ]?|[-]?)+$","gi");
	if (!myRegExpr.test(theForm.FirstName.value))
	{
	    alert("Please enter only letters, spaces or hyphens in the First Name field.");
	    theForm.FirstName.focus();
	    return (false);
	}
	
	if (theForm.Surname.value == "")
	{
	alert("Please enter surname.");
	theForm.Surname.focus();
	return (false);
	}
  
	myRegExpr.compile("^([A-Z]+[']?|[ ]?|[-]?)+$","gi");
	if (!myRegExpr.test(theForm.Surname.value))
	{
	    alert("Please enter only letters, spaces, apostrophe or hyphen in the Surname field.");
	    theForm.Surname.focus();
	    return (false);
	}
	
	if (theForm.Email.value == "")
	{
	alert("Please enter a value in the \"Email\" field.");
	theForm.Email.focus();
	return (false);
	}

	myRegExpr.compile("^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$","gi");
	if (!myRegExpr.test(theForm.Email.value))
	{
		alert("This does not appear to be a valid email address.")
	    theForm.Email.focus();
	    return (false);
	}
	
	if (!theForm.Terms.checked)
	{
	alert("Please read and agree to Terms.");
	theForm.Terms.focus();
	return (false);
	}
	return (true);
}		