<!--
function FrontPage_Form1_Validator(theForm)
{

  if (theForm.Societa.value == "")
  {
    alert("Please enter a value for the \"Societa\" field.");
    theForm.Societa.focus();
    return (false);
  }

  if (theForm.Societa.value.length < 3)
  {
    alert("Please enter at least 3 characters in the \"Societa\" field.");
    theForm.Societa.focus();
    return (false);
  }

  if (theForm.PersonaDaContattare.value == "")
  {
    alert("Please enter a value for the \"Persona da Contattare\" field.");
    theForm.PersonaDaContattare.focus();
    return (false);
  }

  if (theForm.PersonaDaContattare.value.length < 4)
  {
    alert("Please enter at least 4 characters in the \"Persona da Contattare\" field.");
    theForm.PersonaDaContattare.focus();
    return (false);
  }

  if (theForm.Telefono.value == "")
  {
    alert("Please enter a value for the \"Telefono\" field.");
    theForm.Telefono.focus();
    return (false);
  }

  if (theForm.Telefono.value.length < 6)
  {
    alert("Please enter at least 6 characters in the \"Telefono\" field.");
    theForm.Telefono.focus();
    return (false);
  }

  var checkOK = "0123456789-/ \t\r\n\f";
  var checkStr = theForm.Telefono.value;
  var allValid = true;
  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;
    }
  }
  if (!allValid)
  {
    alert("Please enter only digit, whitespace and \"/\" characters in the \"Telefono\" field.");
    theForm.Telefono.focus();
    return (false);
  }

  var checkOK = "0123456789-/ \t\r\n\f";
  var checkStr = theForm.Fax.value;
  var allValid = true;
  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;
    }
  }
  if (!allValid)
  {
    alert("Please enter only digit, whitespace and \"/\" characters in the \"Fax\" field.");
    theForm.Fax.focus();
    return (false);
  }

//  if (theForm.Email.value == "")
//  {
//    alert("Please enter a value for the \"Email\" field.");
//    theForm.Email.focus();
//    return (false);
//  }

//  if (theForm.Email.value.length < 5)
//  {
//    alert("Please enter at least 5 characters in the \"Email\" field.");
 //   theForm.Email.focus();
//    return (false);
//  }

  if (theForm.Prodotto.value == "")
  {
    alert("Please enter a value for the \"Prodotto\" field.");
    theForm.Prodotto.focus();
    return (false);
  }

  if (theForm.Prodotto.value.length < 3)
  {
    alert("Please enter at least 3 characters in the \"Prodotto\" field.");
    theForm.Prodotto.focus();
    return (false);
  }

//  if (theForm.VsCodice.value == "")
 // {
 //   alert("Please enter a value for the \"Codice\" field.");
 //   theForm.VsCodice.focus();
 //   return (false);
//  }

//  if (theForm.VsCodice.value.length < 3)
//  {
//    alert("Please enter at least 3 characters in the \"Codice\" field.");
//    theForm.VsCodice.focus();
//    return (false);
//  }

  if (theForm.Quantita.value == "")
  {
    alert("Please enter a value for the \"Quantita\" field.");
    theForm.Quantita.focus();
    return (false);
  }

  if (theForm.Quantita.value.length < 1)
  {
    alert("Please enter at least 1 characters in the \"Quantita\" field.");
    theForm.Quantita.focus();
    return (false);
  }

//  if (theForm.DataGiorno.selectedIndex < 0)
//  {
 //   alert("Please select one of the \"Data\" options.");
//    theForm.DataGiorno.focus();
//    return (false);
//  }

//  if (theForm.DataGiorno.selectedIndex == 0)
//  {
//    alert("The first \"Data\" option is not a valid selection.  Please choose one of the other options.");
//    theForm.DataGiorno.focus();
//    return (false);
//  }

//  if (theForm.DataMese.selectedIndex < 0)
//  {
//    alert("Please select one of the \"Mese\" options.");
 //   theForm.DataMese.focus();
//    return (false);
 // }

//  if (theForm.DataMese.selectedIndex == 0)
//  {
//    alert("The first \"Mese\" option is not a valid selection.  Please choose one of the other options.");
//    theForm.DataMese.focus();
 //   return (false);
 // }

//  if (theForm.DataAnno.selectedIndex < 0)
//  {
//    alert("Please select one of the \"Anno\" options.");
 //   theForm.DataAnno.focus();
 //   return (false);
//  }

//  if (theForm.DataAnno.selectedIndex == 0)
//  {
//    alert("The first \"Anno\" option is not a valid selection.  Please choose one of the other options.");
//    theForm.DataAnno.focus();
//    return (false);
//  }

  if (theForm.Difetto.value == "")
  {
    alert("Please enter a value for the \"Difetto da Segnalare\" field.");
    theForm.Difetto.focus();
    return (false);
  }

  if (theForm.Difetto.value.length < 6)
  {
    alert("Please enter at least 6 characters in the \"Difetto da Segnalare\" field.");
    theForm.Difetto.focus();
    return (false);
  }
  return (true);
}
//-->