Print Range

Tonto111

Board Regular
Joined
Jun 17, 2002
Messages
83
I have several macro that filter out the data on a spreadsheet. However, this messes up the print range. Is there a way to have the print range adjust automatically?
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.

BigC

Well-known Member
Joined
Aug 4, 2002
Messages
851
When I work with filtered lists I always include a "fence" at the bottom of my data table (I insert new rows above the fence if I need more data rows) This fence is a row in which each cell contains "-" (repeated "-")
I then hook the bottom limit of my print area to this row, so that when-ever I filter the list, my print area always covers the items displayed.

HTH
BigC
 

Andrew Poulsom

MrExcel MVP
Joined
Jul 21, 2002
Messages
73,092
What do you mean by "this messes up the print range"? The Print_Area range reference is not affected by filtering.
 

Tonto111

Board Regular
Joined
Jun 17, 2002
Messages
83
I've tried to manually set the print range for every 40 lines or so, but since one filter results in ten rows of data, another in 20 and another results in 40 rows, the filters that should result in only one page of data give me much more, with only a few lines on each page. Is there a way for the macro to set an acceptable print range?
 

Andrew Poulsom

MrExcel MVP
Joined
Jul 21, 2002
Messages
73,092
Remove your manual page breaks and let Excel do it for you. If you want to limit the number of rows per page adjust the top and/or bottom margins in Print Preview.
 

Forum statistics

Threads
1,144,770
Messages
5,726,186
Members
422,661
Latest member
foxleinlady

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top