获取子窗体控件的名称 [英] Get Name Of Subform Control

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

问题描述

当我单击子窗体中的控件时,在包含子窗体的主窗体上返回子窗体控件的

名称的语法是什么?


MsgBox" MySubform in in& &安培; < ???? >


谢谢,


莎莉

When I click on a control in a subform, what is the syntax to return the
name of the subform control on the main form that contains the subform?

MsgBox "MySubform is in " & < ???? >

Thanks,

Sally

推荐答案

2005年1月15日星期六20:18:05 GMT,Sally < sm ***** @ notmyemail.com>

写道:


mysubformcontrol.Form!mycontrol


mysubformcontrol是父

表单上子表单控件的名称。

使用.Form,你可以进入子表单。

mycontrol is子窗体中控件的名称。


-Tom。

On Sat, 15 Jan 2005 20:18:05 GMT, "Sally" <sm*****@notmyemail.com>
wrote:

mysubformcontrol.Form!mycontrol

mysubformcontrol is the name of the subform control on the parent
form.
With .Form you step into the subform.
mycontrol is the name of the control in the subform.

-Tom.

当我点击子窗体中的控件时,在包含子表单的主窗体上返回子窗体控件名称的语法是什么?

MsgBox" MySubform在& &安培; < ???? >

谢谢,

Sally
When I click on a control in a subform, what is the syntax to return the
name of the subform control on the main form that contains the subform?

MsgBox "MySubform is in " & < ???? >

Thanks,

Sally






Sally写道:
当我单击子窗体中的控件时,返回的语法是什么?
包含
子窗体的主窗体上的子窗体控件的名称?

MsgBox" MySubform在& &安培; < ???? >
When I click on a control in a subform, what is the syntax to return
the name of the subform control on the main form that contains the
subform?

MsgBox "MySubform is in " & < ???? >




可以在
http://www.mvps.org/access/forms/frm0031.htm


-

Joan Wild

Microsoft Access MVP



A handy reference for this can be found at
http://www.mvps.org/access/forms/frm0031.htm

--
Joan Wild
Microsoft Access MVP


嗨莎莉


因为您在子窗体中单击控件,所以可以保证子窗体具有焦点,因此其容器控件是主窗体上的活动

控件。因此,你可以这样得到:

Me.Parent.ActiveControl.Name

-

祝你好运!


Graham Mandeno [访问MVP]

新西兰奥克兰


Sally < SM ***** @ notmyemail.com>在消息中写道

新闻:1U ***************** @ newsread3.news.pas.earthl ink.net ...
Hi Sally

Because you are clicking on a control in the subform, you can guarantee that
the subform has the focus, and therefore its container control is the active
control on the main form. Therefore, you can get it like this:
Me.Parent.ActiveControl.Name
--
Good Luck!

Graham Mandeno [Access MVP]
Auckland, New Zealand

"Sally" <sm*****@notmyemail.com> wrote in message
news:1U*****************@newsread3.news.pas.earthl ink.net...
当我单击子窗体中的控件时,在包含子窗体的主窗体上返回子窗体控件名称的语法是什么?

MsgBox" MySubform是在 &安培; < ???? >

谢谢,
Sally
When I click on a control in a subform, what is the syntax to return the
name of the subform control on the main form that contains the subform?

MsgBox "MySubform is in " & < ???? >

Thanks,

Sally



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

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