How to Referance a subform in code

  • Thread starter Thread starter mattc66 via AccessMonster.com
  • Start date Start date
M

mattc66 via AccessMonster.com

I need to modify the below syntax to work with SubForms:

I need the same as below - except for .Parent it would be?? I cannot find in
help what i'd expect. I am thinking it would be .child or subform or
something like that...

Set mForm = ctl.Parent

Anyone know the answer?
 
A bit unusual to do this?

But try this:

Set mForm = Me.NameOfSubformControl.Form

where NameOfSubformControl is the name of the subform control (the control
that holds the subform object).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top