Smart questions
Smart answers
Smart people
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Member Login

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips now!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

Join Tek-Tips
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

LINK TO THIS FORUM!

Add Stickiness To Your Site By Linking To This Professionally Managed Technical Forum.
Just copy and paste the
code below into your site.

Partner With Us!

"Best Of Breed" Forums Add Stickiness To Your Site
Partner Button
(Download This Button Today!)

Feedback

"...Your site was well structured and I found what I was looking for in about 2 minutes. I am looking forward to participating with you in the future..."

Geography

Where in the world do Tek-Tips members come from?
ertweety (TechnicalUser)
5 Jun 12 20:11
I'm losing my mind. Really need some help with this one!!!

ISSUE: Access module is exporting 3 identical pages for each vendor report.

WHAT I WOULD LIKE: I would like each vendor report to be exported to pdf with only one page.


There are 3 lines of data in the source data (MT_SC_S15_FINAL_TABLE) for each vendor and this is why the report is producing 3 reports for each vendor. Unfortunately, there is really nothing I can do to change the data. I wrote it in SQL and brought it into Access in order to produce the report.

Is there a way only to export the first page of the report for each vendor?

Attaced is the database. Copy of MASTER Tower_Scorecards.zip


Here is my module code for export which you can see in the attached database;

Option Compare Database
Function exp()
Dim rsDat As Recordset
Set rsDat = CurrentDb.OpenRecordset("Select distinct [VENDOR#] From [EDISPATCH_TOWERS]")
rsDat.MoveFirst
Do
DoCmd.OpenReport "rpt_scorecards", acViewPreview, , "[VENDOR#] = '" & rsDat(0) & "'"
DoCmd.OutputTo acOutputReport, "rpt_scorecards", acFormatPDF, "C:\ACCOUNT_" & rsDat(0) & ".pdf"
DoCmd.Close acReport, "rpt_scorecards", acSaveNo
rsDat.MoveNext
Loop Until rsDat.EOF
MsgBox "Tower Scorecards Exported"
End Function


Post Cross-reference - http://www.access-programmers.co.UK/forums...878#post1160878
http://www.accessforums.net/programming/ex...html#post123150
http://www.utteraccess.com/forum/Export-Report-Page-t1988119.html

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close