惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Recent Announcements
Recent Announcements
J
Java Code Geeks
雷峰网
雷峰网
Microsoft Security Blog
Microsoft Security Blog
博客园 - 【当耐特】
腾讯CDC
博客园 - 司徒正美
B
Blog RSS Feed
博客园 - 三生石上(FineUI控件)
I
InfoQ
N
Netflix TechBlog - Medium
L
LangChain Blog
博客园_首页
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
T
Tailwind CSS Blog
MyScale Blog
MyScale Blog
美团技术团队
The Cloudflare Blog
爱范儿
爱范儿
Stack Overflow Blog
Stack Overflow Blog
博客园 - 聂微东
H
Help Net Security
Martin Fowler
Martin Fowler
V
Visual Studio Blog

博客园 - .net技術

makefile c语言难点 线程同步(转) stl学习(转帖2) stl 学习(转帖) visual C++ 6.0开发工具与调试 vc动态装载动态库 详细的MySQL C API CString,string,char*的综合比较 在Linux下安装和使用MySQL 人际关系的55个绝招 一个封装的socket类 一个linux下c++程序 一个网络扫描程序 VC数字图像处理编程 ASCII 一些函数 防盗链IHttpHandler(转自垃圾猪) 按比例显示图片大小
回车改变焦点
.net技術 · 2005-11-16 · via 博客园 - .net技術

回车改变焦点

<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>

posted on 2005-11-16 14:56  .net技術  阅读(295)  评论()    收藏  举报