function keyh(x)
{
    if(x.addEventListener ) {
        x.addEventListener('keydown',this.keyHandler,false);
    } else if(x.attachEvent ) {
        x.attachEvent('onkeydown',this.keyHandler); /* damn IE hack */
    }
}
    function keyHandler(e) {
        var TABKEY = 9;
        if(e.keyCode == TABKEY) {
	//alert("This.id="+this.id)
		if (this.value=="") {
	x=this.id
        x1=x.substr(x.length-2)
        x2=x.substr(0,x.length-2)
	//alert("x="+x+" x1="+x1)
	if(x1 > 0 && this.value=="")
	{
		x1="0"+(x1-1)
		z=x.substr(0,x.length-2)+x1.substr(x1.length-2)
		zz=document.getElementById(z)
		//alert("zz.value="+zz.value)
            this.value = zz.value;
		if(x2=="producto") prd1(this)
		if(x2=="description") prd2(this)
            if(e.preventDefault) {
                e.preventDefault();
            }
            return false;
        }
	}
    }
}

