+ Reply to Thread
Results 1 to 8 of 8

Looping named ranges copy and paste

  1. #1
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Looping named ranges copy and paste

    I wanted to use this to copy named ranges in separate excel sheets. There are atleast 20+ named ranges in the workbook. I set the table with named range so that everytime it changes, I can copy the whole table. tia.

    Please Login or Register  to view this content.

  2. #2
    Forum Expert
    Join Date
    12-24-2007
    Location
    Alsace - France
    MS-Off Ver
    MS 365 Office Suite
    Posts
    5,066

    Re: Looping named ranges copy and paste

    Can you attach a short Excel sample file showing what you want as final result.
    Note: Of course the scope of the name for a activesheet
    - Battle without fear gives no glory - Just try

  3. #3
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,522

    Re: Looping named ranges copy and paste

    Each named range to its own sheet?

  4. #4
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: Looping named ranges copy and paste

    I'm not sure if this is possible. I attached a sample table on the sheet1. And I want to loop the macro each time it finds a named range in sheet1, it will copy it in separate sheet in consecutively manner. The table may sometimes dynamic as it may contains only 3 data, 5 data, etc. it is not fixed. If this is not possible, I can also use the dynamic range using row.xlUp function.

    Not a fixed own sheet, it may vary. Depending on the data.
    Last edited by AliGW; 06-02-2020 at 04:28 AM. Reason: Attachment removed - sensistive data - OP's request.

  5. #5
    Forum Expert
    Join Date
    12-24-2007
    Location
    Alsace - France
    MS-Off Ver
    MS 365 Office Suite
    Posts
    5,066

    Re: Looping named ranges copy and paste

    each time it finds a named range in sheet1, it will copy it in separate sheet
    It means you want to copy only the ranges covered by each name or do you want to copy the names ... take care that ( today) names' scope is workbook.
    Do you want to make the copy from sheet1 to all others sheets ??

  6. #6
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,522

    Re: Looping named ranges copy and paste

    Try
    Please Login or Register  to view this content.
    Last edited by jolivanes; 09-23-2019 at 05:39 PM.

  7. #7
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: Looping named ranges copy and paste

    Nicely done! Thank you jolivanes. And the code you provided make the tabs with the named range too!

    Yes. I want to copy the ranges of each named range in separate sheet individually.

  8. #8
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,522

    Re: Looping named ranges copy and paste

    Thank you for letting us know that your happy with the result.
    Have a good day.

+ 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. Copy and Paste Macro with Named Ranges
    By GavinF in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-27-2018, 04:36 AM
  2. Looping Mutliple Named Resized Ranges in next empty row below another named range
    By gingumdog in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-19-2014, 08:15 PM
  3. Copy/Paste Named Ranges but nothing happens, with no runtime error
    By dietcoke802 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-06-2013, 11:54 AM
  4. Replies: 2
    Last Post: 01-03-2013, 01:29 AM
  5. Copy & paste from cells below named ranges
    By Glio in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-19-2007, 08:15 AM
  6. Copy and paste two named ranges together.
    By ACDenver in forum Excel General
    Replies: 3
    Last Post: 10-20-2005, 07:05 PM
  7. Looping through named ranges
    By JFamilo in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-17-2005, 09:23 AM

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