Selective Printing

dbradley87

New Member
Joined
Oct 13, 2017
Messages
4
Hi there,

I've run into a bit of an issue with an excel I'm working on and was wondering if anyone here might have some input. Here we go...

I have a freeze pane set up on row 6 - followed by default unchanging data from rows 7 all the way to (currently, and will change) row 21073. Default data on the excel sheet runs from rows 7-21073 & columns A-E - with space to enter data on column F(numerical quantities) & column G (dates)

Essentially, on a day to day basis - reports will be created with data entered into column F & G, on any row from 7-21073. The problem is that after this data has been entered - I need to do a print which will include only rows where data was entered in column F and/or G, as well as the frozen pane in rows 1-6.

If anyone has some input or ideas I would really appreciate it - just let me know if any extra information might be needed?

Thanks!
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
Welcome to the Board!

If I understand you correctly, you should just be able to bring the Page Setup, go to the Sheet tab, and enter in the following:
Rows to repeat at top: 1:6
Print area: the other rows you want to print
 
Upvote 0
If the data is always in the same rows on columns F & G then you could put an autofilter on the bottom row of the freeze panes on column F, uncheck the blanks checkbox and apply the filter.
 
Last edited:
Upvote 0
Thanks all.

The key here is that multiple people will be accessing the excel, adding data in columns F & G - and then printing.

The end result I'm hoping for is to find some sort of setting or macro that will make it so all these people need to do is a regular print, and only the rows with data entered into column F & G will show on the print - in addition to the 1-6 rows on the frozen pane.

There are several options to selectively print manually, but the key is that I'm looking for a "dummy proof" automatic solution - that will detect and only print rows with data entered into column F & G

Thanks again!
 
Upvote 0
If the data is always in the same rows on columns F & G then you could put an autofilter on the bottom row of the freeze panes on column F, uncheck the blanks checkbox and apply the filter.


The data will always be entered into columns F & G, but on any one or multiple rows from 7-21k~

The key is that I need only those rows with data entered on column F & G to print - automatically

Thanks again!
 
Upvote 0
If you want some sort of automation, it is probably going to require VBA. Is that OK?
If so, how many tabs are in your workbook?
What is the name of the tab that you will be printing off?
 
Upvote 0
If you want some sort of automation, it is probably going to require VBA. Is that OK?
If so, how many tabs are in your workbook?
What is the name of the tab that you will be printing off?


That seems to be exactly correct with all the reading I've been doing on this! The workbook will have 1 tab, titled "Sheet1"

Thanks again, I really do appreciate it!
 
Upvote 0
Code:
Sub FilterPrint()
    Dim MyRng As Range
    With Sheets("Sheet1")
        Set MyRng = .Range("A1:G" & .Range("A" & Rows.Count).End(xlUp).Row)
        .Rows("6:6").AutoFilter
        MyRng.AutoFilter Field:=6, Criteria1:="<>"
        .PageSetup.PrintArea = MyRng.Address
        .PrintPreview [COLOR="#006400"]'change to .PrintOut when sure it is working correctly[/COLOR]
        MyRng.AutoFilter
        .PageSetup.PrintArea = ""
    End With
End Sub
 
Upvote 0

Forum statistics

Threads
1,223,228
Messages
6,170,871
Members
452,363
Latest member
merico17

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
Back
Top