var theNumOfWords = 0;function NotCompleteAlert(theField){	alert('Sie muessen mindestens das Feld "' + theField + '" ausfuellen, bevor das Wort hinzugefuegt werden kann!');	return;}	// NotCompleteAlertfunction AddWord(){	var theForm = self.document.Eingabe;	var theWortart = theForm.Wortart.options[theForm.Wortart.selectedIndex].value;	var theNewWord;		if (theForm.Wort.value == '')	{		NotCompleteAlert("Nom. etc.");		return	}	// if		if (theNumOfWords > 255)	{		alert("Sie d&uuml;rfen maximal 256 Woerter eingeben!");	}	// if	theNewWord = '<PARAM NAME="wort'+theNumOfWords +'" VALUE="' +theWortart+ ','+theForm.Wort.value;	if (theWortart != 'x')	{		if (theForm.Genitiv.value == '')		{			NotCompleteAlert("Genitiv etc.");			return;		}	// if		theNewWord += ','+theForm.Genitiv.value;				if (theWortart != 'p')		{			if (theForm.Genus.value == "")			{				NotCompleteAlert("Genus etc.");				return;			}	// if			theNewWord += ','+theForm.Genus.value;						if (theWortart == 'v')			{				if (theForm.PVP.value == "")				{					NotCompleteAlert("PVP etc.");					return;				}	// if				theNewWord += ','+theForm.PVP.value;			}	// if		}	// if	}	// if		theNewWord += ',';	if (theForm.NumOfTraductions.value=="")		theNewWord += '1';	else if (theForm.NumOfTraductions.value > 4)	{		alert('Die Anzahl moeglicher Bedeutungen darf 4 nicht uebersteigen!');		return;	}	// else if	else		theNewWord += theForm.NumOfTraductions.value;			theNewWord += ',';		if (theForm.Uebersetzung.value == '')	{		NotCompleteAlert("Uebersetzung");		return;	}	// if		theNewWord += theForm.Uebersetzung.value + ','+theForm.AdditionalInfo.value +'">';		theForm.WortFeld.value += theNewWord;	theForm.Wortart.selectedIndex = 0;	theForm.Wort.value = '';	theForm.Genitiv.value = '';	theForm.Genus.value = '';	theForm.PVP.value = '';	theForm.NumOfTraductions.value = '1';	theForm.Uebersetzung.value = '';	theForm.AdditionalInfo.value = '';		theNumOfWords++;}	// AddWordfunction GetParams(){	var theForm = self.document.Eingabe;	var theText;	theText = '<PARAM NAME="modus" VALUE="' +				theForm.Modus.options[theForm.Modus.selectedIndex].value + '">\n';	theText += (theForm.genitiv.checked?'<PARAM NAME="genitiv" VALUE="on">\n':'');	theText += (theForm.genus.checked?'<PARAM NAME="genus" VALUE="on">\n':'');	 	theText += (theForm.perfekt.checked?'<PARAM NAME="perfekt" VALUE="on">\n':'');	theText += (theForm.pvp.checked?'<PARAM NAME="PVP" VALUE="on">\n':'');	theText += (theForm.praesens.checked?'<PARAM NAME="praesens" VALUE="on">\n':'');	theText += (theForm.kasus.checked?'<PARAM NAME="kasus" VALUE="on">\n':'');	theText += (theForm.adjektiv.checked?'<PARAM NAME="adjektiv" VALUE="on">\n':'');	theText += (theForm.stammformen.checked?'<PARAM NAME="stammformen" VALUE="on">\n':'');	theText += (theForm.genusgenitiv.checked?'<PARAM NAME="genus/genitiv" VALUE="on">\n':'');	theText += (theForm.kurzabfrage.checked?'<PARAM NAME="kurzabfrage" VALUE="on">\n':'');	return theText;}	// GetParamsfunction Get2000Year(theDate){	var theYear = theDate.getYear();		if (theYear < 1000)		theYear += 1900;			return theYear;}	// Get2000Yearfunction GetFooter(){	var theDate = new Date();	var theForm = self.document.Eingabe;	return '<HR><P>Um die &Uuml;bung zu beenden, schliessen Sie bitte das Fenster.<P><HR><P>Letzter Update: ' +theDate.getDate()+'.'+(1+theDate.getMonth())+'.'+Get2000Year(theDate)+ '<BR>';}	// GetFooterfunction CreateFile(){	var theForm = self.document.Eingabe;	var theParams = GetParams();	if (theParams == '')		return;		var theTitle = theForm.Titel.value;		if (theTitle == '')		theTitle = 'JavaVoci-&Uuml;bung';	var theText = '<HTML><HEAD><TITLE>'+theTitle+'</TITLE><META HTTP-EQUIV="Content-Script-Type" CONTENT="text/javascript"></HEAD><BODY BGCOLOR="white"><H1>'+theTitle+'</H1><HR>'+	'<applet code="JavaVoci.class"'+ ((theForm.javaurl.value != '')?('codebase="' + theForm.javaurl.value):'') + '" archive="JavaVoci.jar" alt="JavaVoci (Java-Applet)" width="523" height="397">\n'+	theForm.WortFeld.value+'\n' +	theParams+'\nDas Applet "JavaVoci" funktioniert nur, wenn Ihr Browser Java unterst&uuml;tzt.</applet>\n' +	'<P ALIGN="right"><SMALL>&copy; by L. Hartmann, Z&uuml;rich 1999</SMALL><P>'+	GetFooter()+'\n</BODY></HTML>';		var theWindow = self.open("","Neues_Dokument");	theWindow.document.write(theText);	theWindow.document.close();}	// CreateFile