Print Macro

Piotrwilczak

New Member
Joined
May 18, 2017
Messages
2
Hello

We are using the macro below to print a copy on Plain and Letterhead at the same time . The application which we use is on remote server and our print server is on local network ( I think we use something called Remote Desktop Easy Print which kind of redirects the print job from the server on which the application reside to print server in our office). For the macro to work we have to edit it and change the redirected values every day.
Is there a way to edit this macro to specify the range of numbers (lets say from 1 to 65,000) no matter to which number printing is redirected macro would still work?



Sub Macro1()
'
' Macro1 Macro
'
'
ActivePrinter = _
"TCL012 - Team A - Headed on abctclfls001 (redirected 613)"
Application.PrintOut FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentWithMarkup, Copies:=1, Pages:="", PageType:= _
wdPrintAllPages, Collate:=True, Background:=True, PrintToFile:=False, _
PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
ActivePrinter = "TCL012-Team A on abctclfls001 (redirected 613)"
Application.PrintOut FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentWithMarkup, Copies:=1, Pages:="", PageType:= _
wdPrintAllPages, Collate:=True, Background:=True, PrintToFile:=False, _
PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
PrintZoomPaperHeight:=0
End Sub

I would be grateful if you could assist .

Thank You


Piotr
 

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
The problem is not can you code something, the problem is *what* to code. There has to be a method for the macro to retreive information about what the daily redirection is. Having a list of 65,000 entries that you sequentially try is not the solution. Better to figure out a way to have Remote Desktop Easy Print write the daily redirect to a file that you could then read with VBA. Btw, you're aware that this is a Word VBA question, not Excel. Forum Rule #4 prevents me from being specific, but there are web resources dedicated to Word VBA.
 
Upvote 0
Hi rlv01

Thank You very much for your reply :) . I thought that VBA work the same for Word and Excel ?
Anyways once again thank you for your help .

Regards

Piotr
 
Upvote 0

Forum statistics

Threads
1,215,700
Messages
6,126,301
Members
449,308
Latest member
VerifiedBleachersAttendee

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top