Hi all,
I'm attempting to have a dropdown on the main form of my database change the record source for a subform with the AfterUpdate function.
I'm completely new to VBA so I may have some sort of weird syntax error but I get the following error when I try and use the dropdown:
"Run-time error '2450':
Microsoft Access cannot find the referenced form 'Table1Subform'"
I'm attempting to select the Subform with the following:
Code:
Forms!Table1Subform.RecordSource = strNewRecord
If this subform is embedded within the main form, do I have to reference the main form and then the subform, or should I reference the subform directly?
If I attempt to do:
Code:
Forms!Form1!Table1Subform.RecordSource = strNewRecord
then I get the following error:
"Run-time error '438':
Object doesn't support this property or method"
Thanks.