Okay, I know how to do this but it's just plain not working. I swear I've done this before. No matter how I vary the code I keep getting "you entered an expression that has an invalid reference to the property Form/Report"
I'm trying to set the RecordSource of one subform during the OnCurrent event of another subform on the SAME main form.
Main form: frmMain
Subform1: frmSub1 (in this form's OnCurrent event)
Subform2: frmSub2 (setting the source for this one)
in frmSub1's OnCurrent event:
Me.Parent!frmSub2.Form.RecordSource = "blah blah blah..."
Forms!frmMain!frmSub2.Form.RecordSource = "blah blah blah..."
If I do this in debug window:
I get the result I expect. But if I do this in the debug window:
I get the error noted above. Of course the error has nothing to do with the SQL string that I'm using to set the RecordSource. The error is saying it just plain doesn't like my form references. My eyes are starting to go nuts on this one. Can anyone see where the problem is?
Note that these subforms are NOT nested. They are separate subforms side by side on the same main form.