选择控件 [英] Selecting Controls

查看:74
本文介绍了选择控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遇到一个小问题,在VB6下,它很简单。我有一个

组合框和2个文本框,tb1和tb2。好吧,当执行certian动作时,我需要选择(激活)tb2,只留下组合框和tb1

。我做数据输入appz,鼠标到达和敲击的次数越少,

的速度就越快。


谢谢,

JLW

I''m having a small issue with this, under VB6, it was simple. I have a
combo box and 2 textboxes, tb1 and tb2. Well, when a certian action is
performed, I need to select (activate) tb2, leaving the combobox and tb1
alone. I do data entry appz, and the less mouse reaching and key strokes,
the faster things can go.

Thanks,
JLW

推荐答案

" JLW" <关于*** @ someplace.com>在消息中写道

news:uK ************** @ TK2MSFTNGP10.phx.gbl ...
"JLW" <as***@someplace.com> wrote in message
news:uK**************@TK2MSFTNGP10.phx.gbl...
我有这个问题很小,在VB6下,很简单。我有一个
组合框和2个文本框,tb1和tb2。
当执行certian动作时,我需要选择(激活)tb2
I''m having a small issue with this, under VB6, it was simple. I have a
combo box and 2 textboxes, tb1 and tb2.
when a certian action is performed, I need to select (activate) tb2




部分取决于特定行动,但是


Me.tb2.Focus()


应该可以解决问题。


HTH,

Phill W.



Depends partially on the "certain action", but

Me.tb2.Focus()

should do the trick.

HTH,
Phill W.


不幸的是,这并没有成功。我只想弄清楚WTF,

但是,让我们从这个方法中试试吧。假设你有一个按钮,当你点击它时,在代码中,你如何设置tb2激活,将光标放在其中。

我试过了在静脉中,它已经达到要求我有这个功能的价值。


谢谢,

JLW

Phill。 W" < P.A.Ward@o-p-e-n -.- A-C -.-的u-K>在消息中写道

news:ca ********** @ yarrow.open.ac.uk ...
Unfortunatly, that did not do the trick. I''m just trying to figure out WTF,
but, let''s try it from this aproach. Say you have a button, and when you
click it, in the code, how do you set tb2 active, putting the cursor in it.
I''ve tried in vein, and it''s gotten to the point where it''s required I have
this functionality.

Thanks,
JLW
"Phill. W" <P.A.Ward@o-p-e-n-.-a-c-.-u-k> wrote in message
news:ca**********@yarrow.open.ac.uk...
" JLW" <关于*** @ someplace.com>在消息中写道
新闻:英国************** @ TK2MSFTNGP10.phx.gbl ...
"JLW" <as***@someplace.com> wrote in message
news:uK**************@TK2MSFTNGP10.phx.gbl...
我有一个小问题这个,在VB6下,很简单。我有一个
组合框和2个文本框,tb1和tb2。
当执行certian动作时,我需要选择(激活)tb2
I''m having a small issue with this, under VB6, it was simple. I have a
combo box and 2 textboxes, tb1 and tb2.
when a certian action is performed, I need to select (activate) tb2



部分取决于关于特定动作,但是

Me.tb2.Focus()

应该可以解决这个问题。

HTH, Phill W.



Depends partially on the "certain action", but

Me.tb2.Focus()

should do the trick.

HTH,
Phill W.



我甚至尝试过Me.ActiveControl = tb2但仍然没有快乐。我投入了一个

Application.DoEvents()作为衡量标准....

" Phill。 W" < P.A.Ward@o-p-e-n -.- A-C -.-的u-K>在消息中写道

news:ca ********** @ yarrow.open.ac.uk ...
I have even tried Me.ActiveControl=tb2 and still no joy. And I threw in an
Application.DoEvents() for good measure....
"Phill. W" <P.A.Ward@o-p-e-n-.-a-c-.-u-k> wrote in message
news:ca**********@yarrow.open.ac.uk...
" JLW" <关于*** @ someplace.com>在消息中写道
新闻:英国************** @ TK2MSFTNGP10.phx.gbl ...
"JLW" <as***@someplace.com> wrote in message
news:uK**************@TK2MSFTNGP10.phx.gbl...
我有一个小问题这个,在VB6下,很简单。我有一个
组合框和2个文本框,tb1和tb2。
当执行certian动作时,我需要选择(激活)tb2
I''m having a small issue with this, under VB6, it was simple. I have a
combo box and 2 textboxes, tb1 and tb2.
when a certian action is performed, I need to select (activate) tb2



部分取决于关于特定动作,但是

Me.tb2.Focus()

应该可以解决这个问题。

HTH, Phill W.



Depends partially on the "certain action", but

Me.tb2.Focus()

should do the trick.

HTH,
Phill W.



这篇关于选择控件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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