By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,082 Members | 2,108 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,082 IT Pros & Developers. It's quick & easy.

Trying to Change a Variable in Main Form from Subform

P: 4
From an OnChange in VBA in a SUB form I am trying to change a value in the main form.

Basically this is to let me know at a quick glance if any of the data has changed on the sub form.

Any Ideas?
Jun 30 '10 #1

✓ answered by MikeTheBike

@Talnus
Hi

Try this in the on current even

Me.Parent.txtControlName = "Value to be set"

Any question/problems, please ask.


MTB

Share this Question
Share on Google+
3 Replies


Expert 100+
P: 634
@Talnus
Hi

Try this in the on current even

Me.Parent.txtControlName = "Value to be set"

Any question/problems, please ask.


MTB
Jul 1 '10 #2

NeoPa
Expert Mod 15k+
P: 31,494
Your code on the sub-form can refer to the main form as Me.Parent. From there only you know which controls are available and which should be updated.

Welcome to Bytes!
Jul 1 '10 #3

P: 4
Awsome this was to simple, it worked perfectly Thank you
Jul 1 '10 #4

Post your reply

Sign in to post your reply or Sign up for a free account.