Add print function

  • Thread starter Thread starter Tim
  • Start date Start date
T

Tim

I would like to add a print button/link right on my worksheet that will print
some of my sheets but not all in the workbook. Any help would be appreciated.
 
That's easy enough to do but you will have to furnish the sheet names to
print or the sheet names not to print. You would also have to furnish the
range to print in each sheet or some logic that Excel can use to find the
range to print. HTH Otto
 
Might be just as easy to CTRL + Click on the sheet tabs to print and
File>Print>Active Sheets.

Or a short macro on a button.

Sub Print_Selected()
ActiveWindow.SelectedSheets.PrintOut
End Sub

If you will always be printing the same sheets go with this.

Sub print_some()
ActiveWorkbook.Worksheets(Array("Sheet1", _
"Sheet4", "Sheet5")).PrintOut
End Sub


Gord Dibben MS Excel MVP
 
Gord,

I will always print the same sheets. How do I add a button and then put the
macro on it?

Thanks!!
 
Button on a sheet?

View>Toolbars>Forms.

Select the button icon then draw a button on your sheet.

Right-click and "Assign Macro"

Button on a Toolbar?

View>Toolbars>Customize>Commands.

Scroll down to "Macros" and select.

Drag a Smiley face up to a Toolbar then right-click on it and assign the
macro to that.

You can change the Smiley to another Icon should you wish and change the
Tooltip name also.


Gord
 
Back
Top