none
Word 2013 Print Current Page Macro Problem RRS feed

  • Question

  • We create a Macro that we use to printer the current page. Then we add a link to that macro in the Quick Access Toolbar.  In Word 2007 this macro allows us to print envelopes however, in 2013 the same process causes the envelopes to print with the wrong orientation.

    Macro Process:

    Start with a new Word document.

    1.       Click on the VIEW Tab
    2.    Select the Arrow under Macros
    3.       Select “Record Macro” from the drop down menu
    4.       Change the macro name to “PrintCurrentPage”

    Confirm the store macro in says “All Documents (Normal.dot)

    Click OK


    1.       Select File > Print

    Change the Print Range from “All” to “Current Page”

    Select the “Print” button

    1.       Select the Arrow under Macro

    Select “Stop Recording” from the drop down menu

    1.       Click the dropdown arrow on the Quick Access Toolbar and choose More Commands…

    1.       Under “Choose Commands From:” change the dropdown to Macros

    1.       Select “Normal.NewMacros.PrintCurrentPage and click on the Add>> button between the two columns to add it to the Quick Access Toolbar

    10.  Click on the Modify… button under the right column

    11.  Select an icon to represent your new macro (I use the printer on the second row – it’s different from the regular print icon because it doesn’t have the green check mark on it)

    Change the Display name to “Print Current Page”

    Click OK


    Click OK

    You should now have two printer icons on your Quick Access Toolbar.  The one on the left with the green checkmark is the Print All button and the one on the right is the Print Current Page button.

    Sorry about the formatting I copied it from Word 2013 that have screen shots and bullets and that doesn't copy/paste here very well.

    We have documents that the first page in an envelope, we use the Print Current Page macro to try and print the envelope with a single mouse click, however the Macro causes the envelope to print with the wrong orientation.  If we go through the File > Print select  Print Current Page and select Print the envelope prints correctly.  

    Is there a setting I need to adjust or what?

    Tuesday, May 12, 2015 7:01 PM

Answers

  • Hi,

    >>however the Macro causes the envelope to print with the wrong orientation.  <<

    As far as I know, we can use PageSet to change the orientation. Please check the code whether it change the orentation.

    Also here is a demo that change the orientation for your reference:

    If Selection.PageSetup.Orientation = wdOrientPortrait Then
            Selection.PageSetup.Orientation = wdOrientLandscape
        Else
            Selection.PageSetup.Orientation = wdOrientPortrait
        End If
    Regards & Fei


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Thursday, May 14, 2015 7:13 AM
    Moderator

All replies

  • Hi,

    This is the forum to discuss questions and feedback for Microsoft Office, your issue need some VBA code, I'll move your question to the MSDN forum for Word

    https://social.msdn.microsoft.com/Forums/en-US/home?forum=worddev&filter=alltypes&sort=lastpostdesc

    The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.

    George Zhao
    TechNet Community Support


    It's recommended to download and install Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office programs.

    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact tnmff@microsoft.com.
    Wednesday, May 13, 2015 7:21 AM
  • Hi,

    >>however the Macro causes the envelope to print with the wrong orientation.  <<

    As far as I know, we can use PageSet to change the orientation. Please check the code whether it change the orentation.

    Also here is a demo that change the orientation for your reference:

    If Selection.PageSetup.Orientation = wdOrientPortrait Then
            Selection.PageSetup.Orientation = wdOrientLandscape
        Else
            Selection.PageSetup.Orientation = wdOrientPortrait
        End If
    Regards & Fei


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Thursday, May 14, 2015 7:13 AM
    Moderator