function Zip_Validator(theForm)
{
  if (theForm.ZipCode.value == "")
  {
    alert("Please enter a value for the Zip Code field.");
    theForm.ZipCode.focus();
    return (false);
  }

  if (theForm.ZipCode.value.length < 5)
  {
    alert("Please enter 5 characters in the Zip Code field.");
    theForm.ZipCode.select();
    return (false);
  }

  if (theForm.ZipCode.value.length > 5)
  {
    alert("Please enter 5 characters in the Zip Code field.");
    theForm.ZipCode.select();
    return (false);
  }

  var checkOK = "0123456789-";
  var checkStr = theForm.ZipCode.value;
  var allValid = true;
  var validGroups = true;
  var decPoints = 0;
  var allNum = "";
  for (i = 0;  i < checkStr.length;  i++)
  {
    ch = checkStr.charAt(i);
    for (j = 0;  j < checkOK.length;  j++)
      if (ch == checkOK.charAt(j))
        break;
    if (j == checkOK.length)
    {
      allValid = false;
      break;
    }
    allNum += ch;
  }
  if (!allValid)
  {
    alert("Please enter only numeric values in the ZipCode field.");
    theForm.ZipCode.select();
    return (false);
  }
  return (true);
}