Share via

Auto Export PDF Report

Anonymous
2022-05-26T17:32:47+00:00

Hi,

I have a form with buttons when clicked export a pdf reports to a folder on my pc.

I've been using this database for years to export pdf reports.

When I click the button to export a pdf report nothing happens, not even an error.

This is the code I'm using:

DoCmd.OutputTo acOutputReport, "rptData", acFormatPDF, "C:\Users\pjsco\Documents\Data.pdf", False

When I open the same database on my laptop I don't have a problem exporting a pdf report.

I have tried uninstalling Office on my pc and reinstalling but I still can't export a pdf report.

This started happening about a week ago.

Does anyone have a idea what's going on?

Thanks,

Paul

Microsoft 365 and Office | Access | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2022-05-30T23:28:58+00:00

Hi Tina,

I've been working on this all day trying different things.

I'm not sure what I did but for some reason the buttons when clicked started exporting the reports to a folder on my pc.

I really appreciate the support you provide me.

Again thanks and have a great day.

Paul

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

6 additional answers

Sort by: Most helpful
  1. Anonymous
    2022-05-27T14:48:32+00:00

    Hi Scott,

    I appreciate your reply. Please look at my post to Tina.

    Have a great day,

    Paul

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2022-05-27T14:47:11+00:00

    Hi Tina,

    The Access on my pc is 64bit and the Access on my laptop is 32bit. My laptop is 64bit. I thought Office would install the 64bit when the system was 64bit. I guess I was wrong.

    Using my pc I created a new form with a button to export a report and the same thing, nothing. I created a new database on my pc using some of the same data and created a form with a button when clicked would export a report and it worked just fine.

    I can open and export the reports manually just fine.

    Since I'm able to use the data in a new database I know there isn't anything wrong with the data. As much as I hate it I think I'm going to have to create a new database using the same data creating new queries, forms and reports.

    I was hoping that there was away going to be one of those, I know what the problem is moments but I don't foresee that. The only thing I can think of is there's something corrupt within the database. I've been working with Access for some 20 years I've never seen anything like this.

    I really appreciate the effort,, have a great day,

    Paul

    Was this answer helpful?

    0 comments No comments
  3. ScottGem 68,830 Reputation points Volunteer Moderator
    2022-05-27T03:11:56+00:00

    Have you checked to make sure the report opens properly?

    Was this answer helpful?

    0 comments No comments
  4. Anonymous
    2022-05-27T02:57:30+00:00

    Dear Paul,

    Thanks for posting in Microsoft Community.

    According to your description, I understand you have an issue that nothing happens when you click button on a form to export a PDF report in a database, however, when you open the same database on your laptop, the issue doesn't happen.

    We understand the issue has affected your work. Sorry for the inconvenience.

    To do troubleshooting for the issue, we'd like to confirm following information.

    1.Does the issue only appear in a specific database? If you try the code in a different database, does it work?

    2.As you mentioned using the same database works on your laptop but doesn't work on your PC, you may try to compare the Access application on your laptop and PC. Are there any differences between the 2 Access applications?

    For example, do they have same Version and Channel? You can check it from File>Account, check the information next to 'About Access'.

    And are they all 64-bit Access or 32-bit Access?

    Thanks for your patience and understanding!

    Sincerely,

    Tina | Microsoft Community Moderator

    Was this answer helpful?

    0 comments No comments