bonjour,
j'ecris un code que je veux faire fonctionner sur plusieurs postes mas qui du coup exige une synthaxe diffrrent pour cela j'ai tente les ccodes suivants
ouCode:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 Private Sub Worksheet_SelectionChange(ByVal Target As Range) On Error Resume Next Application.ActivePrinter = "PDFCreator on Ne02:" ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _ "PDFCreator on Ne01:", Collate:=True Next: Application.ActivePrinter = "PDFCreator on Ne01:" ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _ "PDFCreator on Ne01:", Collate:=True End Sub
ni l'un ni l'aute ne fonctionne. quequ'un connaitrait il la synthaxe correcte?Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 Private Sub Worksheet_SelectionChange(ByVal Target As Range) On Error GoTo blabla Application.ActivePrinter = "PDFCreator on Ne02:" ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _ "PDFCreator on Ne01:", Collate:=True blabla:Application.ActivePrinter = "PDFCreator on Ne01:" ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _ "PDFCreator on Ne01:", Collate:=True End Sub
merci d'avance, cheers