[VB.NET]一个简单的问题?

来源:互联网 发布:淘宝站外活动平台 编辑:程序博客网 时间:2024/05/04 16:50
VB.NET源码-156个实用实例哦……<script type="text/javascript"><!--google_ad_client = "pub-8333940862668978";/* 728x90, 创建于 08-11-30 */google_ad_slot = "4485230109";google_ad_width = 728;google_ad_height = 90;//--></script><script type="text/javascript"src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
一个简单的问题?
比如我有两个文本框 A,B
现在我在A文本框中输了东西,然后想敲一下回车,焦点转到B文本框中.
如何实现?
__________________________________________________________________________
在A的OnKeyDown事件里写

if e.KeyCode == Enter then
TextBoxB.Focus();
end if
__________________________________________________________________________
Private Sub TextBox1_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles TextBox1.KeyDown
If e.KeyCode = Keys.Enter Then
TextBox2.Focus()
End If
End Sub
__________________________________________________________________________
web 下要用js实现
__________________________________________________________________________
原创粉丝点击