George Too
Registered User.
- Local time
- Today, 05:31
- Joined
- Aug 12, 2002
- Messages
- 198
Can anyone tell why is this code asking me to enter parameter values twice? Isn't supposed to get the values from the combo boxes?
(this code is in the after_update event in the last of 3 combo boxes that filter the records).
***********************************************
Dim strSQLSF As String
strSQLSF = " SELECT * FROM tblMain "
strSQLSF = strSQLSF & " WHERE tblMain.Complaint_Information = '" & cboComplaintField & "' And "
strSQLSF = strSQLSF & " tblMain.Customer = '" & cboCustomerField & "' And "
strSQLSF = strSQLSF & " tblMain.Location = " & cboLocationField
Me.subfrmQuery.LinkChildFields = ""
Me.subfrmQuery.LinkMasterFields = ""
Me.subfrmQuery.LinkChildFields = "Complaint_Information;Customer;Location"
Me.subfrmQuery.LinkMasterFields = "Complaint_Information;Customer;Location"
Me.RecordSource = strSQLSF
Me.Requery
***************************************************
Thanks,
George
(this code is in the after_update event in the last of 3 combo boxes that filter the records).
***********************************************
Dim strSQLSF As String
strSQLSF = " SELECT * FROM tblMain "
strSQLSF = strSQLSF & " WHERE tblMain.Complaint_Information = '" & cboComplaintField & "' And "
strSQLSF = strSQLSF & " tblMain.Customer = '" & cboCustomerField & "' And "
strSQLSF = strSQLSF & " tblMain.Location = " & cboLocationField
Me.subfrmQuery.LinkChildFields = ""
Me.subfrmQuery.LinkMasterFields = ""
Me.subfrmQuery.LinkChildFields = "Complaint_Information;Customer;Location"
Me.subfrmQuery.LinkMasterFields = "Complaint_Information;Customer;Location"
Me.RecordSource = strSQLSF
Me.Requery
***************************************************
Thanks,
George