Queenofmycastle
Board Regular
- Joined
- Oct 27, 2009
- Messages
- 62
- Office Version
- 2016
- Platform
- Windows
This is one of my most used VBA formulas. I want to share my file with other offices. Is there a way to have it so that the printer can be changed without knowing VBA?
Thanks so much!
Sub PrintEntireSetJ6()
Dim i As Integer
Application.ActivePrinter = "iR-ADV C350 PCL 5c on Ne06:"
[J6].FormulaR1C1 = "1"
ExecuteExcel4Macro _
"PRINT(1,,,1,,,,,,,,2,""iR-ADV C350 on Ne03:"",,TRUE,,FALSE)"
For i = 2 To 25
[J6].FormulaR1C1 = CStr(i)
ExecuteExcel4Macro "PRINT(1,,,1,,,,,,,,2,,,TRUE,,FALSE)"
Next i
[J6].FormulaR1C1 = "1"
End Sub
Thanks so much!
Sub PrintEntireSetJ6()
Dim i As Integer
Application.ActivePrinter = "iR-ADV C350 PCL 5c on Ne06:"
[J6].FormulaR1C1 = "1"
ExecuteExcel4Macro _
"PRINT(1,,,1,,,,,,,,2,""iR-ADV C350 on Ne03:"",,TRUE,,FALSE)"
For i = 2 To 25
[J6].FormulaR1C1 = CStr(i)
ExecuteExcel4Macro "PRINT(1,,,1,,,,,,,,2,,,TRUE,,FALSE)"
Next i
[J6].FormulaR1C1 = "1"
End Sub