Como logro utilizar tecla enter como tab en asp.net

julianserna
05 de Diciembre del 2005
Como logro utilizar tecla enter como tab en asp.net, se que es tema viejo pero no se como hacerlo

Jose Mauro
05 de Diciembre del 2005
<input id=Campo1 onKeypress="EnterTab(this.id)"
function EnterTab(CampoAtual){

if(event.keyCode !=13){
return
}


Txt=document.getElementsByTagName("INPUT")

for(var x=0; x< Txt.length; x++){

if(x == Txt.length-1){
x = 0

while(Txt[x].style.display =="none"){
x++
}

Txt[x].focus();
return;
}
if(CampoAtual == Txt[x].id){

//Se o item estiver invisível procura pelo primeiro visível
//=========================================================
while(Txt[x+1].style.display =="none" && x<Txt.length){
x++
//Se atigir o final da tabela volta para o início
//===============================================
if(x == Txt.length-1){
x = 0
while(Txt[x].style.display =="none"){
x++
}
Txt[x].focus();
return;
}
}
Txt[x+1].focus();
return;
}
}
}