function SmallWindow71(wintype) {
SmallWin71=window.open(wintype,"SmallWin71","toolbar=no,directories=no,status=no,scrollbars=yes,menubar=yes,width=415,height=200"); SmallWin71.window.focus() }

function SmallWindow40(wintype) {
SmallWin40=window.open(wintype,"SmallWin40","toolbar=yes,directories=no,status=no,scrollbars=yes,menubar=yes,width=620,height=490"); SmallWin40.window.focus() }

function Form1_Validator(theForm)
{

  if (theForm.deckungssumme.selectedIndex == 0)
  {
    alert("Die erste \"deckungssumme\"-Option ist keine gültige Wahl. Wählen Sie eine der anderen Optionen.");
    theForm.deckungssumme.focus();
    return (false);
  }

  if (theForm.tankort.selectedIndex == 0)
  {
    alert("Die erste \"tankort\"-Option ist keine gültige Wahl. Wählen Sie eine der anderen Optionen.");
    theForm.tankort.focus();
    return (false);
  }

  if (theForm.fassung.value == "")
  {
    alert("Geben Sie einen Wert in das Feld \"Fassungsvermögen\" ein.");
    theForm.fassung.focus();
    return (false);
  }

  var checkOK = "0123456789-";
  var checkStr = theForm.fassung.value;
  var allValid = 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("Geben Sie nur Ziffern in das Feld \"Fassungsvermögen\" ein.");
    theForm.fassung.focus();
    return (false);
  }

  var chkVal = allNum;
  var prsVal = parseInt(allNum);
  if (chkVal != "" && !(prsVal > "0" && prsVal <= "300000"))
  {
    alert("Geben Sie einen Wert größer als \"0\" und kleiner oder gleich \"300000\" in das Feld \"Fassungsvermögen\" ein.");
    theForm.fassung.focus();
    return (false);
  }

  if (theForm.immobilienart.selectedIndex == 0)
  {
    alert("Die erste \"immobilienart\"-Option ist keine gültige Wahl. Wählen Sie eine der anderen Optionen.");
    theForm.immobilienart.focus();
    return (false);
  }

  if (theForm.targru.selectedIndex == 0)
  {
    alert("Die erste \"Tarifgruppe\"-Option ist keine gültige Wahl. Wählen Sie eine der anderen Optionen.");
    theForm.targru.focus();
    return (false);
  }
  return (true);
}


