ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   print macro for a list (https://www.excelbanter.com/excel-programming/357449-print-macro-list.html)

[email protected]

print macro for a list
 
I have 2 worksheets, A and B, and there is a cell "b2" that contains a
drop down list of division names (used data validation list). When each
different name on this drop down list is selected the 2 worksheets
change to show the results of this specific division. I would like to
make a macro that prints these 2 sheets for all the names on this drop
down list.

Please help

Thanks


Tom Ogilvy

print macro for a list
 
Assume the source for the data validation list on a sheet named Data in cells
A1:A10 . further assume the B2 cell with the dropdown list is on a sheet
named Dropdown. Adjust to fit your actual situation
Sub PrintData()
dim cell as Range
for each cell in Worksheets("Data").Range("A1:A10")
Worksheets("Dropdown").Range("B2").Value = cell
worksheets(Array("A","B")).Printout
Next
End sub


--
Regards,
Tom Ogilvy


" wrote:

I have 2 worksheets, A and B, and there is a cell "b2" that contains a
drop down list of division names (used data validation list). When each
different name on this drop down list is selected the 2 worksheets
change to show the results of this specific division. I would like to
make a macro that prints these 2 sheets for all the names on this drop
down list.

Please help

Thanks



[email protected]

print macro for a list
 
Thanks a lot, really appreciate the help!



All times are GMT +1. The time now is 02:21 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com