+ Reply to Thread
Results 1 to 2 of 2

Copy values from one range and paste in another with some slight modifications

  1. #1
    Forum Contributor
    Join Date
    04-11-2012
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2010
    Posts
    245

    Copy values from one range and paste in another with some slight modifications

    So I'm trying to copy data from row 3 through 20 and paste it repetitively beginning at row 21 based on the value of an input box. However, with each paste iteration I want to:

    a) clear the pasted data in columns L & M
    b) increment the values in the column K by 1

    To illustrate what I'm looking for, I've attached my workbook which includes a sheet entitled 'Holes'. This worksheet displays the results of my code as it exists now (see below). The tab entitled 'What I want' displays the results I'm trying to achieve.

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

  2. #2
    Forum Contributor
    Join Date
    09-18-2023
    Location
    Geogia, USA
    MS-Off Ver
    365
    Posts
    109

    Re: Copy values from one range and paste in another with some slight modifications

    Try this code, I like to stay away from copy and pasting:

    Please Login or Register  to view this content.
    edit: removed pasterange and colorindex vars that aren't used any longer
    Attached Files Attached Files
    Last edited by jdelano; 03-30-2024 at 09:27 AM.

+ 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. macro to filter range then copy paste range only and insert as values.
    By Lukeb123 in forum Excel Programming / VBA / Macros
    Replies: 19
    Last Post: 08-24-2021, 06:50 AM
  2. [SOLVED] Macro to copy cells from a selected range and just paste values back to that same range
    By catscats11 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 01-18-2019, 02:59 PM
  3. [SOLVED] Copy & Paste all unique values from a range
    By liamfrancis2013 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-01-2016, 07:09 AM
  4. Replies: 2
    Last Post: 09-16-2014, 10:13 AM
  5. [SOLVED] Copy and paste range as values to specific sheet/range
    By lukestkd in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 03-06-2014, 09:48 PM
  6. copy and paste a range of values
    By strucad in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 07-13-2012, 09:56 AM
  7. Slight modification to copy paste loop
    By rhudgins in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 10-19-2010, 04:09 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