subform calls

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have formA which contains subformB. I can call a subroutine formA from
subformB by doing:

forms!formA.subroutine

Which works great. However, I can't call a subroutine in subformB from FormA

forms!formB.subroutine

Generates the error "2450 Access can't find the form 'FormB' referred to in
a macro expression or Visual Basic Code"

the subroutines in formA and subformB are public subroutines.

What am I doing wrong? Any help would be appreciated.
 
PeterM said:
I have formA which contains subformB. I can call a subroutine formA
from subformB by doing:

forms!formA.subroutine

Which works great. However, I can't call a subroutine in subformB
from FormA

forms!formB.subroutine

Generates the error "2450 Access can't find the form 'FormB' referred
to in a macro expression or Visual Basic Code"

the subroutines in formA and subformB are public subroutines.

What am I doing wrong? Any help would be appreciated.

The reference for a form being displayed inside a subform control is...

Forms!ParentFormName!SubFormCONTROLName.Form
 

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

Similar Threads

Subform query 1
Calling another form 2
subform 1
subforms 1
using vb code to move the record selector of a SubForm 1
Finding Totals from two diff date ranges 5
A problem reading a file 2
control name literal 1

Back
Top