跳到另一个文本框... [英] jumping to another textbox...

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

问题描述

我再来一次MR。新手2 vba。我有另一种情况,我似乎无法弄清楚。我有8行文本框(每行3个 - 数量,零件和数量)。我的问题是我在1到24之间有相应的标签。但是,如果只使用了一行,那么我必须通过所有其他文本框来选项以进入下一个焦点或控制文本框(总材料)。有没有一种方法可以对此进行编码,这样一旦我完成任何行(无论是第1行还是第7行),它就会进入总材料文本框。


谢谢

HI me again MR. Newbie 2 vba. I have another situation I can''t seem to figure out. I have 8 rows of text boxs (3 in each row - Quantity, Parts & Amount). My problem is that I have them tabbed accordingly 1 thru 24. But what if there is only one row used then I have to tab thru all the other text boxes to get to the next focus or controling text box (total materials). Is there a way I can code this so that once Im done with whatever row (whether it be row 1 or row 7) that it just goes to the total materials textbox.

Thank you

推荐答案

是否可以为前24个文本框指定相同名称但带有索引?

如果是这样,你可以使用CTRL + TAB跳转到total的下一个代码。文本框。 (见附件)

Is it possible to give the first 24 textboxes the same name but with an index ?
If so, you can use next code in which a CTRL+TAB jumps to the "total" textbox. (see attachment)

展开 | 选择 | Wrap | 行号


@ggeu


谢谢你的回复,但我不太清楚你的意思。这是否意味着当用户在文本框中输入数据时,她必须使用shift键跳到文本总计框?
@ggeu
Thank you for your response, But I''m not quite sure what you mean. Does this mean that when the user is inputting data into the text boxs she has to use the shift key to skip to the text total box?


@ggeu


我试图用另一个用户表单测试你的代码,这就是我得到的。 程序声明与具有相同名称的事件或程序的描述不匹配。我做错了什么?

@ggeu
I attempted to test your code in another user form and this is what I got. "procedure declaration does not match description of event or procedure having the same name. did I do something wrong?

展开 | 选择 | Wrap | 行号


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

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