In my code, I build a where condition to be used in
conjunction with docmd.openreport and I assign it to a
variable vReportCondition.
vReportCondition = "[Sample_Stream] = 'AQU'"
When I run the following:
Docmd.OpenReport vReportName,
acViewPreview,,vReportCondition
the variable vReportCondition has no effect.
When I run:
Docmd.OpenReport vReportName,
acViewPreview,,"[Sample_Stream] = 'AQU'"
the report returns the right results
What am I doing wrong?
conjunction with docmd.openreport and I assign it to a
variable vReportCondition.
vReportCondition = "[Sample_Stream] = 'AQU'"
When I run the following:
Docmd.OpenReport vReportName,
acViewPreview,,vReportCondition
the variable vReportCondition has no effect.
When I run:
Docmd.OpenReport vReportName,
acViewPreview,,"[Sample_Stream] = 'AQU'"
the report returns the right results
What am I doing wrong?