<script language="vbscript">
<!--
Sub TextBox1_onkeydown //TextBox1,TextBox2,DropDownList1为web控件;
if window.event.keyCode=13 then
EnterTextBox_1.TextBox2.focus() //EnterTextBox_1为 <form id=" EnterTextBox_1" runat="server">
end if
End Sub
Sub TextBox2_onkeydown
if window.event.keyCode=13 then
EnterTextBox_1.DropDownList1.focus()
end if
End Sub
Sub DropDownList1_onkeydown
if window.event.keyCode=13 then
EnterTextBox_1.TextBox1.focus()
end if
End Sub
//-->
</script>
另外一种:
<script language="vbscript">
<!--
Sub document_onkeydown
if window.event.keyCode=13 then
window.event.keyCode=9
end if
End Sub
//-->
</script>