call a function of subform from the main form

J

Jerry Qu

Trying to work around the problem with the previous post. I just found I can
not call public sub(function) of subform from the main form too:


in the subform

Public Sub fillData(strSQL as String)

msgbox strSQL

.....

end sub


in the main form:


Me!subfrmControlName.form.fillData strSQL
get error....




but it works fine without parent/child relation:


forms!subformName.fillData strSQL


please help

TIA

Jerry
 

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