VBA - Print Selection

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

In an excel workbook I have columns A - J, I want a macro that will select a
print range based on..... column "G". Column G will either be populated with
(blank) or "Bring In". Once sorted the rows with Bring In will be on the top
of the sheet, which is the rows that I want printed.

Example... If the first 38 rows have "Bring In" in column "G" I want the
print range A1:J38 to print.

Any ideas?

TFTH,
Tom
 
The VBA is a recorder of steps. Turn it on and record the processes you
would like to have repeted over and over ,then turn it off.
When you have finished your macro TEST IT. Then polish it up using VBE if
you have minor changes you need to make.
Next attach your sequence to a Icon.
Have fun.

WLM
 
Maybe you can drop the sort and use data|filter|autofilter (add a header row if
you don't have one).

Then filter on that column G to show just the values you want.

Print those visible rows

And data|filter|Show all
to see everything.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top