ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Choosing printer in a printing macro (https://www.excelbanter.com/excel-programming/333630-choosing-printer-printing-macro.html)

\Jean-Jerome Doucet via OfficeKB.com\

Choosing printer in a printing macro
 
Hi,

In a printing macro, is it possible to implement an menu option to choose the
printer (I have many printers)? If yes, any ideas how?

I quoted my macro.

Thx!

Werner

Quote:


Sub PrintRows()

Dim lstRw As Long
Dim lstRwPlusTwo As Long
Dim Times As String

'Je détermine le nombre d'unités locatives à traiter.
Let lstRw = Sheets("Formulaire").Range("a65536").End(xlUp).Row
lstRwPlusTwo = lstRw + 2

'With Worksheets("Formulaire").PageSetup
' .PrintTitleRows = "$1:$1"
'End With

Rows(1 & ":" & lstRwPlusTwo).Select

Times = InputBox("Entrez le nombre de copie à imprimer: ", "Copies to Print",
1)

Selection.PrintOut Copies:=Times, Collate:=True


End Sub

--
Message posted via http://www.officekb.com

DM Unseen

Choosing printer in a printing macro
 
use

Application.Dialogs(xlDialogPrinterSetup).Show

DM Unseen


\Jean-Jerome Doucet via OfficeKB.com\

Choosing printer in a printing macro
 
DM Unseen, thank you a lot! It did exactly the right thing.

Have a good day!

JJD

--
Message posted via http://www.officekb.com


All times are GMT +1. The time now is 04:05 AM.

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