B
barefoot_traveler via AccessMonster.com
First--the disclaimer--I am in no way a programmer, but I am working
diligently to support my team in any way possible. With that said, I have
painstakingly created a simple build SQL string code in Access Visual Basic
Editor:
Private Sub Command8_Click()
Dim SQL As String
SQL = "SELECT * " & _
"FROM [BCSG_CARDFILE] " & _
"WHERE ((([BCSG_CARDFILE].[IMPORT_FILENAME]) Between " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboDateFrom.Value & _
"""" & _
" And " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboDateTo.Value & _
"""" & _
" And (([BCSG_CARDFILE].[EMPLOYER_GRP_NO])= " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboGrpNo.Value & _
"""" & _
") " & _
" And (([BCSG_CARDFILE].[CONT_CD])= " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboContCd.Value & _
"""" & _
" )) "
This basically creates the SQL query from the form I created. What I need to
do is display the results of this query in a subform below the form. I have
no clue where to go from here.
Any assistance/guidance would be greatly appreciated.
Thanx,
diligently to support my team in any way possible. With that said, I have
painstakingly created a simple build SQL string code in Access Visual Basic
Editor:
Private Sub Command8_Click()
Dim SQL As String
SQL = "SELECT * " & _
"FROM [BCSG_CARDFILE] " & _
"WHERE ((([BCSG_CARDFILE].[IMPORT_FILENAME]) Between " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboDateFrom.Value & _
"""" & _
" And " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboDateTo.Value & _
"""" & _
" And (([BCSG_CARDFILE].[EMPLOYER_GRP_NO])= " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboGrpNo.Value & _
"""" & _
") " & _
" And (([BCSG_CARDFILE].[CONT_CD])= " & _
"""" & _
Forms![BCSG_CARDFILE_SEARCH]!cboContCd.Value & _
"""" & _
" )) "
This basically creates the SQL query from the form I created. What I need to
do is display the results of this query in a subform below the form. I have
no clue where to go from here.
Any assistance/guidance would be greatly appreciated.
Thanx,