S
steventu
Hi Everyone,
I like to add a print button (that will select several worksheets and
print them) in my excel worksheet. I have recorded my action using the
macro recorder the problem is I can't select the printer everytime I
run the macro it print in the background without asking the user to
select the printer and uses the default printer.
Can anyone help?? I just want the user to be able to select the desired
printer every time before printing.
My current code:
Sub Print_All()
Sheets(Array("Sheet 1", "Sheet 2", "Sheet 3", "Sheet 5)).Select
'intentionally skip sheet 4
Sheets("Sheet 1").Activate
ActiveWindow.SelectedSheets.PrintOut Preview:=True
Sheets("Sheet 1").Select
End Sub
Thanks,
Steve
I like to add a print button (that will select several worksheets and
print them) in my excel worksheet. I have recorded my action using the
macro recorder the problem is I can't select the printer everytime I
run the macro it print in the background without asking the user to
select the printer and uses the default printer.
Can anyone help?? I just want the user to be able to select the desired
printer every time before printing.
My current code:
Sub Print_All()
Sheets(Array("Sheet 1", "Sheet 2", "Sheet 3", "Sheet 5)).Select
'intentionally skip sheet 4
Sheets("Sheet 1").Activate
ActiveWindow.SelectedSheets.PrintOut Preview:=True
Sheets("Sheet 1").Select
End Sub
Thanks,
Steve