F
Federico
I have a form where two listboxes filter data so a subform quickly displays
filtered records. Coding allows for multiselect, and a SQL string is
generated and applied to the subform recordsource:
Forms!ReviewSamplesResult!Details.Form.RecordSource = strSQL
Since the user needs to be able to print this subform data, I created an
OpenReport command button.
How can I pass the SQL that was built to generate the data for the report?
I tried things like
-----------
Dim strLinkCriteria As String
stDocName = "rptReviewSamplesResult"
strLinkCriteria = Forms!ReviewSamplesResult!Details.Form.RecordSource
DoCmd.OpenReport stDocName, acPreview
-----------
but did not fly. I am not very familiar with using OpenArgs and was
wondering if it could be a way to pass the data. also, don't you need to
provide the RecordSource BEFORE the Report opens?
Thanks for help.
Federico
filtered records. Coding allows for multiselect, and a SQL string is
generated and applied to the subform recordsource:
Forms!ReviewSamplesResult!Details.Form.RecordSource = strSQL
Since the user needs to be able to print this subform data, I created an
OpenReport command button.
How can I pass the SQL that was built to generate the data for the report?
I tried things like
-----------
Dim strLinkCriteria As String
stDocName = "rptReviewSamplesResult"
strLinkCriteria = Forms!ReviewSamplesResult!Details.Form.RecordSource
DoCmd.OpenReport stDocName, acPreview
-----------
but did not fly. I am not very familiar with using OpenArgs and was
wondering if it could be a way to pass the data. also, don't you need to
provide the RecordSource BEFORE the Report opens?
Thanks for help.
Federico