文本框重新关注问题... [英] text box Re focus issue...

查看:106
本文介绍了文本框重新关注问题...的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我有一个包含文本框的表单(城市代码,城市名称),假设当我在``城市代码''文本框中键入``a''时,将会弹出一个窗口(Datagridview),其中包含以``a''开头的城市代码...问题是,当我键入内容时,焦点将移至弹出窗口...我希望光标聚焦在TextBox的当前文本旁边....我该怎么做...请帮助我

Hi,
I have one form containing textboxes(City Code,CityName),suppose when i type ''a'' in City Code textbox , a pop up window(Datagridview) will come Containing citycode starting with ''a''...problem is,when i type something ,focus is moving to pop up window...i want cursor to focus next to the Current text of TextBox....how can i do that...please help me

推荐答案

您是否考虑过使用DropDownList代替TextBox-and-DataGridView组合,还是使用自动完成文本框?
这里有一个示例:自动完成控制 [
Have you considered using either a DropDownList instead of the TextBox-and-DataGridView combination, or using an autocomplete textbox?
There is an example here: Auto-complete Control[^]


这篇关于文本框重新关注问题...的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆