Full Version: Report won't save after changes
UtterAccess Discussion Forums > Microsoft® Access > Access Reports
kgerlitz
I am trying to get a report to save after making changes via code. The code works for changing the printer but the final line (DoCmd.Close acReport, "BirthmotherPREMATCHSevenDay", acSaveYes) does not save the report--and I get no error messages. Any ideas. Thanks

Private Sub Text4_Click()
Dim prt As Printer
DoCmd.OpenReport "BirthmotherPREMATCHSevenDay", acViewDesign
Set Application.Printer = Application.Printers("PDF")
Reports("BirthmotherPREMATCHSevenDay").Printer = Application.Printers("PDF")
DoCmd.Close acReport, "BirthmotherPREMATCHSevenDay", acSaveYes
End Sub
kgerlitz
I tried the following code also with no luck. This is really confusing for me

DoCmd.Save acReport, "BirthmotherPREMATCHSevenDay"
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.