HI
I've a mainform/subform setup. I want to link them but I can't use the master/child links. I spent weeks converting them to use ADODB recordsets and when I try to add links I just get 'data providor could not be located'... I guess that master-child links only work with DAO?
I build and apply an SQL SELECT in the subform's open event and want to incoporate the relevant PK field from the mainform... so my subform recordsource wants to be in the order of.....
SQLLINE = "SELECT TBL1.* FROM My_Table1 WHERE Deleted=False AND TBL1.Addrs_ID = Forms!MyMainFrm.Form!ID"
MySubFrm.Recordsource = SQLLINE
The aim of course, is to get the sunform to keep step when the main form is moved to another record.
I've tried all manner of brackets, square brackets, exclamation marks, dot notations.... Salvador Dali could do no better....
Anyone know how this is done please? There's a quote in http://ss64.com/office/access.html that says
"If you are writing an expression as part of an SQL statement, then use an absolute reference".
But I can't get it working.... thanks
I've a mainform/subform setup. I want to link them but I can't use the master/child links. I spent weeks converting them to use ADODB recordsets and when I try to add links I just get 'data providor could not be located'... I guess that master-child links only work with DAO?
I build and apply an SQL SELECT in the subform's open event and want to incoporate the relevant PK field from the mainform... so my subform recordsource wants to be in the order of.....
SQLLINE = "SELECT TBL1.* FROM My_Table1 WHERE Deleted=False AND TBL1.Addrs_ID = Forms!MyMainFrm.Form!ID"
MySubFrm.Recordsource = SQLLINE
The aim of course, is to get the sunform to keep step when the main form is moved to another record.
I've tried all manner of brackets, square brackets, exclamation marks, dot notations.... Salvador Dali could do no better....
Anyone know how this is done please? There's a quote in http://ss64.com/office/access.html that says
"If you are writing an expression as part of an SQL statement, then use an absolute reference".
But I can't get it working.... thanks