+ Reply to Thread
Results 1 to 7 of 7

Copy range and paste on sheet in same workbook

  1. #1
    Forum Contributor
    Join Date
    04-07-2020
    Location
    New Zealand
    MS-Off Ver
    365
    Posts
    219

    Copy range and paste on sheet in same workbook

    Hi There ,

    I have this short code to copy a range of cells from a template to the last found row on a existing sheet within my workbook. Weird thing is, when its copied (works fine) it leaves that copy border (doted lines) on the sheet that is has been pasted to - further weird that the doted border is not even at the correct location

    is it something in the code perhaps ?

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.

  2. #2
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,239

    Re: Copy range and paste on sheet in same workbook

    Cannot test or see your "marching ants" scenario as no sample file...

    Please Login or Register  to view this content.
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

  3. #3
    Forum Contributor
    Join Date
    04-07-2020
    Location
    New Zealand
    MS-Off Ver
    365
    Posts
    219

    Re: Copy range and paste on sheet in same workbook

    Howzit Sintek , do i replace that entire

    Please Login or Register  to view this content.

    with just this

    Please Login or Register  to view this content.
    and end with

    ActiveSheet.Paste


    End Sub
    Last edited by Chris1976; 09-07-2020 at 06:52 AM.

  4. #4
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,239

    Re: Copy range and paste on sheet in same workbook

    Chris...I do not have a sample file so cannot see what you are wanting to achieve...
    If it is copying from template A2:K and lastrow on Template to first available row on Summary_Maint_List then...
    Please Login or Register  to view this content.
    Also...
    Please take a moment to read our forum rules...here
    Your post does not comply with Rule # 2
    2. Programming code must be enclosed in code tags to improve readability. (A, Z)
    Please Login or Register  to view this content.
    So...Edit your post...Highlight the code and press the # button

  5. #5
    Forum Contributor
    Join Date
    04-07-2020
    Location
    New Zealand
    MS-Off Ver
    365
    Posts
    219

    Re: Copy range and paste on sheet in same workbook

    My apologies I noticed that I did not bracket the code , sorry about that

    Just general question Syntek

    what does the
    Please Login or Register  to view this content.
    (2) mean at the end ?

  6. #6
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,239

    Re: Copy range and paste on sheet in same workbook

    Thanks for amending code tags...Moderators are rather strict on rules...
    Basically just offsets from last row|cell...
    See here
    Last edited by sintek; 09-07-2020 at 07:06 AM.

  7. #7
    Forum Contributor
    Join Date
    04-07-2020
    Location
    New Zealand
    MS-Off Ver
    365
    Posts
    219

    Re: Copy range and paste on sheet in same workbook

    No problem was my fault , cool I will have a read through those

    The code suggestion in post #4, works perfect, thanks again Syntex , much appreciated - much shorter and no more "marching ants"... hehehe!

+ 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 dynamic range from closed workbook paste as table into specific sheet
    By Huskersippi in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-16-2019, 11:35 PM
  2. [SOLVED] copy range A4:A100 and paste on another workbook's sheet but one by one
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-01-2014, 08:11 AM
  3. Replies: 6
    Last Post: 03-26-2014, 11:40 PM
  4. [SOLVED] Code to copy data from a closed workbook and paste in active workbook using named range.
    By paullie1912 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 02-28-2014, 02:38 AM
  5. Copy same range from multiple sheets and paste into one sheet of active workbook
    By jadown in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-15-2013, 01:41 PM
  6. Simple task: Open a workbook, copy a range, paste into another workbook
    By fbonetti in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-21-2011, 01:12 PM
  7. Copy A Range of Cells Or Sheet and Paste to A New Workbook
    By Nathan123 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-21-2007, 09:24 PM

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