Enterprise Software

Office solution: Printing different views of the same Excel sheet efficiently

This week, learn the solution to last week's Office challenge: What's the most efficient way to print different areas of the same Excel sheet?
Last week, we asked for an efficient solution for printing different areas of the same sheet. Users tend to waste time resetting each print task. Zimmerwoman and I are on the same page with one solution: use custom views. Views save print settings, so you can select a view and print-without resetting anything when you're ready to print. The good news is, users can do this themselves. To set a custom view, arrange everything the way you want, including the print settings. Then, do the following:

  1. Click the View tab.
  2. In the Workbook Views group, click Custom Views.
  3. Click Add.
  4. Enter a name for the view (the print setting option is checked by default).
  5. Click OK.

A second solution is a set of macros using the following generic procedure:

Sub Printrange()
 ActiveSheet.PageSetup.PrintArea = Range("range").Address
 ActiveWindow.SelectedSheets.PrintOut
End Sub

First, you must create range - a named range that includes the data you want to print. Then, run the appropriate macro to print each range, as needed. For instance, you might have three print ranges named Outlook, Sales, and Trends. In this case, you'd have three sub procedures, PrintOutlook, PrintSales, and PrintTrends. A more efficient solution would be to pass a selected range via a user control:

Sub PrintPassedRange(prtrange As String)
 ActiveSheet.PageSetup.PrintArea = Range("prtrange").Address
 ActiveWindow.SelectedSheets.PrintOut
End Sub

You can also use the procedure to set additional print settings, such as orientation, copy number, and so on.

Once again, thanks to everyone who played along!

About

Susan Sales Harkins is an IT consultant, specializing in desktop solutions. Previously, she was editor in chief for The Cobb Group, the world's largest publisher of technical journals.

Editor's Picks