ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   excel how to put a print button in the document (https://www.excelbanter.com/excel-worksheet-functions/137119-excel-how-put-print-button-document.html)

nick l

excel how to put a print button in the document
 
how to put a print button in document to print a range in excel

Gary''s Student

excel how to put a print button in the document
 
Two options:

1. View Toolbars and check Standard
the Standard toolbar has a Print button it

2. put you own button in the worksheet with VBA:

Sub button_maker()
Application.CommandBars("Forms").Visible = True
ActiveSheet.Buttons.Add(290.25, 69, 51.75, 41.25).Select
Selection.OnAction = "printit"
Application.CommandBars("Forms").Visible = False
End Sub


Sub printit()
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
End Sub


The first sub creates a button. The second sub does the printing. This
assumes that the print range has already been established.
--
Gary's Student
gsnu200712


"nick l" wrote:

how to put a print button in document to print a range in excel



All times are GMT +1. The time now is 06:04 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com