+ Reply to Thread
Results 1 to 4 of 4

Print Macro (Code to change the sheet to Landscape)

  1. #1
    Registered User
    Join Date
    02-05-2009
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    18

    Print Macro (Code to change the sheet to Landscape)

    Below is the code I currently using.

    Sub printrecordandreset()
    Application.ScreenUpdating = False
    Sheet3.PrintOut , , 1
    Application.ScreenUpdating = True
    Sheets("StockOutReceipt").Select
    Range("A2:L782").Select
    Selection.ClearContents
    Sheets("FaceSheet").Select
    Range("D15").Select

    End Sub
    At the moment is selecting the correct sheet, as well as the correct information. It is printing it and then reseting the sheet as it should. However it is printing the data in portrait. As a result it is printing a single line of data acorss 3 sheets of A4. In the interest of tidyness and the enviroment, i would like to know how i can amend this code to automatically change the sheet to landscape, before printing.
    Thanks

  2. #2
    Forum Guru
    Join Date
    08-26-2007
    Location
    London
    Posts
    4,606

    Re: Print Macro (Code to change the sheet to Landscape)

    Perhaps with this. Record a macro of you setting it to landscape and use that.
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    02-05-2009
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    18

    Re: Print Macro (Code to change the sheet to Landscape)

    Thanks for the reply mate. I did actauly have that piece of code. However i cant work out how to implement it into my current code. I simply get an error message. Would it be possible for you to show me how?
    Thanks

  4. #4
    Forum Guru
    Join Date
    08-26-2007
    Location
    London
    Posts
    4,606

    Re: Print Macro (Code to change the sheet to Landscape)

    Please can you add code tags to your original post (# sign) so neither of us get into trouble!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1