Home |
Search |
Today's Posts |
#1
|
|||
|
|||
2003 Macro in 2007 Word
I use the following macro in Word 2003 and deployed it out to other users in the firm who were also on 2003. What it does is prints from certain trays, but a nice part of it is it misses out the Print Dialogue Box.
I have just had a guy from another office phone me up and he has been migrated onto Word 2007 - the macro is still doing what it's supposed to do (IE, printing from the correct trays) but it is now (rather annoyingly) displaying the print dialogue box for each time the macro says to print the active document. Is there any way which I can get around this so the macro does not show the print dialogue box every time I run it. Thanks in advance - The current Macro code is: -------- Sub MyPrint() Attribute MyPrint.VB_Description = "Macro recorded 4/20/2009 by jd03" Attribute MyPrint.VB_ProcData.VB_Invoke_Func = "Normal.NewMacros.MyPrint" Dim OriginalFirstPageSetting As Long, OriginalOtherPagesSetting As Long With ActiveDocument.PageSetup OriginalFirstPageSetting = .FirstPageTray OriginalOtherPagesSetting = .OtherPagesTray .FirstPageTray = 257 'was 2 (257 for follow me printer) .OtherPagesTray = 286 'was 257 (286 for follow me printer) ActiveDocument.PrintOut .FirstPageTray = 260 'was 3 (260 for follow me printer) .OtherPagesTray = 260 'was 3 (260 for follow me printer) ActiveDocument.PrintOut .FirstPageTray = OriginalFirstPageSetting .OtherPagesTray = OriginalOtherPagesSetting End With End Sub ------- |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Moving Macro from Word 2003 to 2007 | Microsoft Word Help | |||
Word 2003 Macro not work in Word 2007 | New Users | |||
Word 2003 Macro Crashes Word 2007 | Microsoft Word Help | |||
Macro in word 2003 not working in word 2007 | New Users | |||
WORD 2003 Macro | Microsoft Word Help |