Printing reports from the drop down

Khushalay

Registered User.
Local time
Today, 13:49
Joined
Apr 16, 2016
Messages
180
I have a drop down menu from where the user selects a particular buyer and then click on the show report button and the report for that specific buyers opens in front of him.
This works fine. No issue with that.

When printing reports, the users have to click on each buyer one by one and the report opens and then issue print command. Earlier we had few buyers and it wasnt tiresome but now we have some 30 plus buyers and printing reports becomes a headache, opening each one of them separately and the issuing print command.

Is there anyway, where we can click on All(or something) and all the reports are printed.

(the report is the same, just the buyers are different, design view is one/same)
 
You can make the buyer a list box, then click a Print All button to cycle thru the list to print every persons report.....
Code:
Sub btnPrintAll_click()
For I = 0 to lstBox.listcount-1
   VBuyer = lstBox.itemdata(I).   'Get next item in list
    LstBox = vBuyer        'Set list box.

    Docmd.openreport "rMyReport"
Next
End sub
[\code]
 
I wrote this code, is this ok?

For i = 0 To aa.ListCount - 1
Customer = aa.itemdata(I). 'Get next item in list'
aa = Customer 'Set list box.

DoCmd.OpenReport "cust"
Next

My buyers table name is Customer
Combo box name is aa
report name is cust
 
That should work.
The report must use a query that looks at the listbox to get that customer.
 
Yes, I have query for that purpose.

The program is showing error
 
error in
Customer = aa.itemdata(I). 'Get next item in list'
 

Users who are viewing this thread

Back
Top Bottom