Hello
I have created a form with a combo box that pulls a report based on the parameter choosen. I have gotten the command button on the form for view and print to work correctly but I can get the one for export to snapshot to work correctly.
When it exports it pulls the whole report and it should only pull based on what was selected in the combo box.
Here is what I have:
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "rptLetterApprovalPendingbyHeadofOffice"
stLinkCriteria = "[Head Office]=" & "'" & Me![Head Office] & "'"
DoCmd.SendObject acReport, stDocName, , , , , , , , stLinkCriteria
I have tried different ways to write the DoCmd but nothing has worked so far.
I have created a form with a combo box that pulls a report based on the parameter choosen. I have gotten the command button on the form for view and print to work correctly but I can get the one for export to snapshot to work correctly.
When it exports it pulls the whole report and it should only pull based on what was selected in the combo box.
Here is what I have:
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "rptLetterApprovalPendingbyHeadofOffice"
stLinkCriteria = "[Head Office]=" & "'" & Me![Head Office] & "'"
DoCmd.SendObject acReport, stDocName, , , , , , , , stLinkCriteria
I have tried different ways to write the DoCmd but nothing has worked so far.