accessing a forms subforms subform data... (3 levels deep)

B

Brad Pears

I have an access app that has a main form on which is a subform on which it
inturn has a subform!!!

I am having problems with the syntax to access the final subforms form

main form --> subform --> subform... this is the data I want to access
from a pop up form...

To access a forms subform it's ...
forms![frmMainForm]![frmSubForm].form.txtItem
However, add another subform in the mix and I can't figure it out...

I've tried...
"forms![frmMainForm]![frmSubForm].form.[frmsubsubForm].form.txtItem"

and also tried...
"forms![frmMainForm]![frmSubForm]![frmSubSubform].form.txtItem"

No go...
Any ideas?

Thanks,

Brad
 
M

Marshall Barton

Brad said:
I have an access app that has a main form on which is a subform on which it
inturn has a subform!!!

I am having problems with the syntax to access the final subforms form

main form --> subform --> subform... this is the data I want to access
from a pop up form...

To access a forms subform it's ...
forms![frmMainForm]![frmSubForm].form.txtItem
However, add another subform in the mix and I can't figure it out...

I've tried...
"forms![frmMainForm]![frmSubForm].form.[frmsubsubForm].form.txtItem"

That is acceptable syntax.

I don't how to diagnose a problem given only the fact that
it doesn't work, but double check that you have all the
names spelled correctly. Note that you must refer to the
name of a subform **control**, which might be different from
the name of the form object being displayed in the control.
 

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

Top