Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Setting subform source object

Status
Not open for further replies.

dmaytum

Programmer
Mar 4, 2003
23
US
I have 2 subforms (completely independent of each other) on a main form. When I click on a checkbox on subform1, I want to set the SourceObject of subform2. I've tried for a day different combinations but can not figure it out. Is this possible?I've tried putting this into the On_Click event of the checkbox

Me.Parent!SubformControl2.SourceObject = "frmProduct"
or
Forms!MainForm!SubformControl2.SourceObject = "frmProduct"
and tons of other combos. Any one have any suggestions? Thanks
 
Thanks but I've tried this. I just get an error saying :the expression you entered refers to an object that is closed or doesn't exist". I've seen that reference sheet you sent and I think in that case the two subforms are nested, or else there's something about the SourceObject property. But thanks for taking the time to help!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top