lilmikey1982
Registered User.
- Local time
- Today, 18:02
- Joined
- Jun 26, 2002
- Messages
- 14
I am having some issues with this code. It is meant to use 3 drop down menus, that search a database of pictures. And the first two work great. It's the 3rd one I have a problem with. It keeps asking me for a paramter on the end one. I am VERY not smart at VB, so any help you could offer, would be great. I will copy the part of the code that is giving me problems, and if anyone needs or wants to see the file, I can send it over e-mail or something. Thanks again!
---Start of Code---
Private Sub cboNumericField_AfterUpdate()
Dim strSQLSF As String
strSQLSF = " SELECT * FROM tblDemo "
strSQLSF = strSQLSF & " WHERE tblDemo.RowField = '" & cboRowField & "' And "
strSQLSF = strSQLSF & " tblDemo.ColumnField = '" & cboColumnField & "' And "
strSQLSF = strSQLSF & " tblDemo.NumericField = " & cboNumericField
Me!sfrmForm.LinkChildFields = ""
Me!sfrmForm.LinkMasterFields = ""
Me!sfrmForm.LinkChildFields = "RowField;ColumnField;NumericField"
Me!sfrmForm.LinkMasterFields = "RowField;ColumnField;NumericField"
Me.RecordSource = strSQLSF <b>(It's right here that is highlighted and giving me problems, I think!!)</b>
Me.Requery
End Sub
---Start of Code---
Private Sub cboNumericField_AfterUpdate()
Dim strSQLSF As String
strSQLSF = " SELECT * FROM tblDemo "
strSQLSF = strSQLSF & " WHERE tblDemo.RowField = '" & cboRowField & "' And "
strSQLSF = strSQLSF & " tblDemo.ColumnField = '" & cboColumnField & "' And "
strSQLSF = strSQLSF & " tblDemo.NumericField = " & cboNumericField
Me!sfrmForm.LinkChildFields = ""
Me!sfrmForm.LinkMasterFields = ""
Me!sfrmForm.LinkChildFields = "RowField;ColumnField;NumericField"
Me!sfrmForm.LinkMasterFields = "RowField;ColumnField;NumericField"
Me.RecordSource = strSQLSF <b>(It's right here that is highlighted and giving me problems, I think!!)</b>
Me.Requery
End Sub