+ Reply to Thread
Results 1 to 4 of 4

macro to copy a range, only when another cell has certain value

  1. #1
    Registered User
    Join Date
    05-07-2015
    Location
    herts, england
    MS-Off Ver
    2016
    Posts
    29

    macro to copy a range, only when another cell has certain value

    Hello - quite new to vba, hoping someone can help...

    My spreadsheet copies values from a big list, into several smaller lists - simple. I have a column of rand() cells next to the big list, and am using a macro to sort the rand() list many times and generate the random smaller lists lots of times.

    However, I only want to keep the smaller lists if they meet certain criteria. How do I use vba to copy the smaller lists (paste special) only when a particular cell has a certain value e.g. TRUE ??

    Any help much appreciated
    Last edited by rw2; 05-08-2015 at 02:02 AM.

  2. #2
    Forum Expert
    Join Date
    08-28-2014
    Location
    Texas, USA
    MS-Off Ver
    2016
    Posts
    1,796

    Re: macro to copy a range, only when another cell has certain value

    An example would help, but it shouldn't be any harder than

    Please Login or Register  to view this content.

  3. #3
    Valued Forum Contributor
    Join Date
    01-10-2012
    Location
    Texas
    MS-Off Ver
    Excel 2010
    Posts
    651

    Re: macro to copy a range, only when another cell has certain value

    how bout something like this..?

    Please Login or Register  to view this content.
    Hope I could help - if your post has been solved don't forget to mark it as such.

    Clicking the * below is a great way to say thanks!

    "Drowning in 10 feet of water isn?t any different than drowning in a million feet. And if you can swim, it doesn?t matter how deep the ocean is. At some level, once you realize you?re in water that?s too deep to stand, you have to have a very different approach," - Joi Ito

  4. #4
    Registered User
    Join Date
    05-07-2015
    Location
    herts, england
    MS-Off Ver
    2016
    Posts
    29

    Re: macro to copy a range, only when another cell has certain value

    Thanks, worked great, so simple...

+ 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 copy named range to cell
    By IvanJames in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-22-2014, 11:29 AM
  2. Replies: 1
    Last Post: 01-03-2014, 03:01 AM
  3. RE:- Write Macro to copy a 2 cell range to another 2 cell range down the columns
    By Eire001 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-02-2013, 11:48 PM
  4. Change range of cells within VBA macro and copy and paste to fixed cell range
    By Mannyny in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 07-20-2012, 11:51 AM
  5. Check Box Macro to Copy a Range of Cell
    By macro_beta in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-26-2011, 12:21 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