Results 1 to 8 of 8
  1. #1
    techexpressinc's Avatar
    techexpressinc is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Dec 2008
    Location
    Indiana, USA
    Posts
    151

    Can a report execute generate a file

    My users like to have a one click solution and not click the External Data words to get the report in a file on the PC.

    Is it possible to click the report and the file will be generated on the PC?

    Thanks Russ @scaninc.org

  2. #2
    llkhoutx is offline Competent Performer
    Windows Vista Access 2007
    Join Date
    Jan 2010
    Location
    Houston, Texas USA
    Posts
    373
    How are you opening the report?

    A file could be generated in the ON_Click event if a button is used to open the report.

    A report "OnFormat" event (try the Detail section Onformat event) could be used to put code to generate the file.

  3. #3
    techexpressinc's Avatar
    techexpressinc is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Dec 2008
    Location
    Indiana, USA
    Posts
    151

    the report is run by category reports and click on the report title

    Are you saying if the report is within a form - i could on the start of the report have code behind the on-click to start the report that would create the report within a file on my C: drive My Documents?

    Thx for any pointers, I would think others would have blazed this path before. Or the report to get generated automaticly to my email. The process of creating a report and going to the external source then typing the name in gets old when you have 2 dozen reports to do weekly.

    Russ

  4. #4
    llkhoutx is offline Competent Performer
    Windows Vista Access 2007
    Join Date
    Jan 2010
    Location
    Houston, Texas USA
    Posts
    373
    the report is not "within" a form, it is opened by the click of a button. That event, the click of the button can do other things too.

    For example:

    Private Sub YourButtonName_Click()

    'DoCmd.OpenReport "report1", acViewPreview 'to preview he report
    DoCmd.OpenReport "report1", acViewReport ' to print the report

    'whatever other code you want
    end sub

    In A07, one can export the report to a file using the External Data >> Export Section icons to export to various data types. You can search this forum on doing this programmatically.

    However, previous versions of Access reports do not translate well to files.

  5. #5
    techexpressinc's Avatar
    techexpressinc is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Dec 2008
    Location
    Indiana, USA
    Posts
    151
    Can you run the PDF convert and have it pop into a PDF file?

    That is how we manual click for 25 reports weekly after entering 25 date parameters.

    Thx Rus

  6. #6
    llkhoutx is offline Competent Performer
    Windows Vista Access 2007
    Join Date
    Jan 2010
    Location
    Houston, Texas USA
    Posts
    373
    Yes, look at the Create Data menu Export section. PDF is one of the methods.

  7. #7
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 Access 2007
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    I have implemented Stephan Lebans code in an ac2007 db without any issues. One click and you have a pdf report. Unfortunately I believe the Snapshot feature has been dropped from ac2010 and Stephan's code depends on it.

  8. #8
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 Access 2007
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    You may also wish to look into PDF Printers such as this one.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Pdf Report Generate from Access
    By ACHU in forum Reports
    Replies: 1
    Last Post: 10-29-2009, 07:49 AM
  2. Creating report from Word file
    By jonny in forum Reports
    Replies: 0
    Last Post: 10-15-2009, 03:10 PM
  3. Replies: 0
    Last Post: 02-04-2009, 04:47 AM
  4. Execute Command Interactively
    By zephaneas in forum Programming
    Replies: 1
    Last Post: 11-08-2008, 09:56 AM
  5. Generate Image
    By dbman in forum Import/Export Data
    Replies: 0
    Last Post: 01-31-2008, 10:46 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums