I am attempting to create a form that uses multiple combo boxes to provide selection criteria for a query that is run when a button is submitted. I am stuck with syntax errors and other types of errors when I create a DoCmd.RunSQL "SQL code copied from a query". I am using this as the base to build the selection criteria. I am using a subform to display the data and then plan to create an export file with the query results.
Private Sub btnSubmit_Click()
On Error GoTo Err_btnSubmit_Click
DoCmd.RunSQL "SELECT tblMktBase.*, tblMktBase.Title, tblMktBase.T_YPEINSTI" & _
FROM tblMktBase;"
Would one of you please take a look at this and advise on how to fix? Also any other help with setting this up correctly will be much appreciated. Examples etc.
Thanks, Jketcher
Private Sub btnSubmit_Click()
On Error GoTo Err_btnSubmit_Click
DoCmd.RunSQL "SELECT tblMktBase.*, tblMktBase.Title, tblMktBase.T_YPEINSTI" & _
FROM tblMktBase;"
Would one of you please take a look at this and advise on how to fix? Also any other help with setting this up correctly will be much appreciated. Examples etc.
Thanks, Jketcher