I have a query that is creating the record source for a form (form_load event):
strSQL = SELECT a.ClientID, a.ClientFirstNm, a.ClientLastNm, b.EmployeeFirstNm,b.EmployeeLastNm, b.CaseLoadID
FROM tblClient AS a, tblEmployee AS b
WHERE a.CaseLoadID=b.CaseLoadID And ClientID=[Enter Social Security Number]
Me.RecordSource = strSQL
This works fine, but I also want to use the a.ClientID portion of the recordset in another query to check something else.
What is the syntax for this, I have been trying:
Me.Recordset(0)
Me.Recordset(ClientID)
Me.RecordSource.Fields(0)
Me.RecordSource(0)
Me.RecordSource(ClientID)
It seems straight forward, but I am having no luck....any ideas?
Thanks!
strSQL = SELECT a.ClientID, a.ClientFirstNm, a.ClientLastNm, b.EmployeeFirstNm,b.EmployeeLastNm, b.CaseLoadID
FROM tblClient AS a, tblEmployee AS b
WHERE a.CaseLoadID=b.CaseLoadID And ClientID=[Enter Social Security Number]
Me.RecordSource = strSQL
This works fine, but I also want to use the a.ClientID portion of the recordset in another query to check something else.
What is the syntax for this, I have been trying:
Me.Recordset(0)
Me.Recordset(ClientID)
Me.RecordSource.Fields(0)
Me.RecordSource(0)
Me.RecordSource(ClientID)
It seems straight forward, but I am having no luck....any ideas?
Thanks!