	var pos1 = 19;
	var pos2 = 16;
	var pos3 = 19;
	var pos4 = 16;
	var pos5 = 32;
	var pos6 = 26;
	
function kaufm(x) {
  var k = (Math.round(x * 100) / 100).toString();
  k += (k.indexOf('.') == -1)? '.00' : '00';
  var p = k.indexOf('.');
  return k.substring(0, p) + ',' + k.substring(p+1, p+3);
}
	
	function getST(obj) {
	  field = obj.name;
	  value = checkvalue(obj);
	  if(field == "st1") {
	    wert = pos1 * value;
	    document.shopform.ges1.value = wert.toFixed(2).replace(/\./,",");
	  }  
	  if(field == "st2") {
	    wert = pos2 * value;
	    document.shopform.ges2.value = wert.toFixed(2).replace(/\./,",");
	  }
	  if(field == "st3") {
	    wert = pos3 * value;
	    document.shopform.ges3.value = wert.toFixed(2).replace(/\./,",");
	  }
	  if(field == "st4") {
	    wert = pos4 * value;
	    document.shopform.ges4.value = wert.toFixed(2).replace(/\./,",");
	  }
	  if(field == "st5") {
	    wert = pos5 * value;
	    document.shopform.ges5.value = wert.toFixed(2).replace(/\./,",");
	  }
	  if(field == "st6") {
	    wert = pos6 * value;
	    document.shopform.ges6.value = wert.toFixed(2).replace(/\./,",");
	  }
	  
	  val1 = parseFloat(document.shopform.ges1.value);
	  val2 = parseFloat(document.shopform.ges2.value);
	  val3 = parseFloat(document.shopform.ges3.value);
	  val4 = parseFloat(document.shopform.ges4.value);
	  val5 = parseFloat(document.shopform.ges5.value);
	  val6 = parseFloat(document.shopform.ges6.value);
	  wert = val1 + val2 + val3 + val4 + val5 + val6 + 2;

	  document.shopform.gesamt.value = kaufm(wert.toFixed(2));
	  document.shopform.mwst.value = kaufm(wert.toFixed(2) * 0.19);
	  document.shopform.brutto.value = kaufm(Math.round(wert.toFixed(2) * 1.19/0.01)*0.01);

	  document.shopform.postnetto.value = wert.toFixed(2);
	  document.shopform.postmwst.value = wert.toFixed(2) * 0.19;
	  document.shopform.postbrutto.value = Math.round(wert.toFixed(2) * 1.19/0.01)*0.01;
	}
	
	function checkvalue(obj) {
	  getvalue = eval("document.shopform."+obj.name);
	      return parseInt(getvalue.value);
	}
	

function checkinput(x) {
	if(this.value != parseInt(this.value)){
		window.alert('Bitte geben sie eine ganze Zahl ein.'); 
		this.value = this.defaultValue; document.shopform[x].focus();
	}
	else {
		getST(this)
	}
}