+ Reply to Thread
Results 1 to 6 of 6

Build an "array" of sheets for a single print job

  1. #1
    Registered User
    Join Date
    09-21-2013
    Location
    Alabaster, Alabama
    MS-Off Ver
    Excel 2010
    Posts
    3

    Build an "array" of sheets for a single print job

    I have a workbook with multiple sheets (20) and from time to time need to print various sets of the sheets other than a single sheet or the entire workbook. I have been trying to replicate the VBA code recorded from a manual selection of sheets to be able to select the names of the sheets in a list on my lead (summary) sheet. To date I have been completely unable to programmatically replicate the syntax that is recorded. I need to print them as a single print job to get consecutive page #'s for the printout for the entire set of sheets printed. I hope someone can help me. Here is the recorded code when selecting 2 of the sheets.

    Please Login or Register  to view this content.
    Any help will be greatly appreciated.
    Last edited by MoleChaser; 10-21-2013 at 08:02 PM. Reason: code tags

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,922

    Re: Build an "array" of sheets for a single print job

    Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here



    ([I]T)Please read the forum rules and abide by them in the future. I have added the code tags this time./I]
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Build an "array" of sheets for a single print job

    What happens when you run that code?
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    09-21-2013
    Location
    Alabaster, Alabama
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: Build an "array" of sheets for a single print job

    When the code is run each sheet named within quotes in the sheets.array statement printout in the sequence listed as a single print job. The individual headers and print ranges of each sheet are maintained, but the page #'s span as if it were all in a single worksheet. That is the desired response, I just don't want my users to have to manually create the sheet set and then forget to clear it before saving the sheet.

  5. #5
    Registered User
    Join Date
    09-21-2013
    Location
    Alabaster, Alabama
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: Build an "array" of sheets for a single print job

    I can't get VBA to even build the statement programmatically. The recorded code runs just fine.

  6. #6
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,527

    Re: Build an "array" of sheets for a single print job

    Hi MoleChaser,

    You can use this, though you could also just print the sheets down the list in the 'Summary' tab one by one:

    Please Login or Register  to view this content.
    Regards,

    Robert
    ____________________________________________
    Please ensure you mark your thread as Solved once it is. Click here to see how
    If this post helps, please don't forget to say thanks by clicking the star icon in the bottom left-hand corner of my post

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 0
    Last Post: 08-14-2013, 09:09 AM
  2. Replies: 2
    Last Post: 06-06-2013, 12:45 PM
  3. Create "print array" button
    By davidshluger in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-28-2010, 05:31 PM
  4. Replies: 4
    Last Post: 01-21-2008, 08:22 AM
  5. If changed array formula reduce ""\""\""\ - signs to #Missing, will it make ...
    By Maria J-son in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-05-2006, 08:25 AM

Tags for this Thread

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