I have tried the following pieces of code and all produce an error. I am stumped.
Dim OntimeString, startdate, enddate As String
reportname = "database_Query_Report_by_date2"
'Error Type Mismatch
OntimeString = "[Date Only] >=" + CDate(Text0.Value) + " and [Date Only] <=" + CDate(Text2.Value)
DoCmd.OpenReport reportname, acViewPreview, , OntimeString
Dim OntimeString, startdate, enddate As String
reportname = "database_Query_Report_by_date2"
'Error Type Mismatch
OntimeString = "[Date Only] >=" + Text0.Value + " and [Date Only] <=" + Text2.Value
DoCmd.OpenReport reportname, acViewPreview, , OntimeString
Dim OntimeString, startdate, enddate As String
reportname = "database_Query_Report_by_date2"
startdate = Text0.value
enddate = Text2.value
'Error Type Mismatch
OntimeString = "[Date Only] >=" + startdate + " and [Date Only] <=" + enddate
DoCmd.OpenReport reportname, acViewPreview, , OntimeString
Any Suggestions ?
All I want is the chance to prove money won't make me happy.
Dim OntimeString, startdate, enddate As String
reportname = "database_Query_Report_by_date2"
'Error Type Mismatch
OntimeString = "[Date Only] >=" + CDate(Text0.Value) + " and [Date Only] <=" + CDate(Text2.Value)
DoCmd.OpenReport reportname, acViewPreview, , OntimeString
Dim OntimeString, startdate, enddate As String
reportname = "database_Query_Report_by_date2"
'Error Type Mismatch
OntimeString = "[Date Only] >=" + Text0.Value + " and [Date Only] <=" + Text2.Value
DoCmd.OpenReport reportname, acViewPreview, , OntimeString
Dim OntimeString, startdate, enddate As String
reportname = "database_Query_Report_by_date2"
startdate = Text0.value
enddate = Text2.value
'Error Type Mismatch
OntimeString = "[Date Only] >=" + startdate + " and [Date Only] <=" + enddate
DoCmd.OpenReport reportname, acViewPreview, , OntimeString
Any Suggestions ?
All I want is the chance to prove money won't make me happy.