+ Reply to Thread
Results 1 to 10 of 10

Looking to copy entire row if a cell value is greater than zero

  1. #1
    Registered User
    Join Date
    05-09-2014
    MS-Off Ver
    Excel 2003
    Posts
    41

    Question Looking to copy entire row if a cell value is greater than zero

    any ideas??


    attached a sheet
    If column D is greater than 0 then I want to copy the entire row to Sheet 2

    basically, I only want to see rows with a quantity on Sheet 2

    this is an ongoing, feed so I can't use Filter

    THANKS!!!
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor
    Join Date
    06-29-2014
    Location
    Australia
    MS-Off Ver
    MSO 365
    Posts
    1,104

    Re: Looking to copy entire row if a cell value is greater than zero

    Hello Dadof2,

    This code may help:-

    Please Login or Register  to view this content.
    Here is a sample work book:-

    Let us know if it does the job for you.

    Cheerio,
    vcoolio.
    Attached Files Attached Files

  3. #3
    Valued Forum Contributor
    Join Date
    03-22-2013
    Location
    Australia,NSW, Wirrimbi
    MS-Off Ver
    Excel 2013
    Posts
    1,057

    Re: Looking to copy entire row if a cell value is greater than zero

    Hi.

    this is an ongoing, feed so I can't use Filter
    Can you explain that.. it would be much fast to:

    1. Autofilter your range by column D for values >0.

    2. Copy the visible rows after autofilter to the other sheet. No loop needed..

    Why can't you use autofilter?

  4. #4
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Looking to copy entire row if a cell value is greater than zero

    Hi Dadof2,

    I didn't think to remove duplicates like coolio - but this works with your sample:

    Please Login or Register  to view this content.
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  5. #5
    Registered User
    Join Date
    05-09-2014
    MS-Off Ver
    Excel 2003
    Posts
    41

    Re: Looking to copy entire row if a cell value is greater than zero

    Thanks for the help!

  6. #6
    Registered User
    Join Date
    05-09-2014
    MS-Off Ver
    Excel 2003
    Posts
    41

    Re: Looking to copy entire row if a cell value is greater than zero

    Okay, I ran it and have a question

    The first time it runs it works, but if I run it again (say later in the day) I get the old info and and new bonds that meet the criteria. How do I get it to clear the Sheet2 and give me a fresh look every time??

    Thanks
    Mark

  7. #7
    Registered User
    Join Date
    05-09-2014
    MS-Off Ver
    Excel 2003
    Posts
    41

    Re: Looking to copy entire row if a cell value is greater than zero

    Quote Originally Posted by apo View Post
    Hi.



    Can you explain that.. it would be much fast to:

    1. Autofilter your range by column D for values >0.

    2. Copy the visible rows after autofilter to the other sheet. No loop needed..

    Why can't you use autofilter?

    Doing this, do I have to manually click the auto-filter each time? Currently, I pull in the info using an API and would like this to automatically look for the bonds with greater than zero quantity and run. I am trying to do this with as little steps as possible. I will set this up and have some "older" users use it so it needs to be as dummy proof as possible. does that make sense???

    THX
    Mark

  8. #8
    Valued Forum Contributor
    Join Date
    03-22-2013
    Location
    Australia,NSW, Wirrimbi
    MS-Off Ver
    Excel 2013
    Posts
    1,057

    Re: Looking to copy entire row if a cell value is greater than zero

    Hi..

    Try this..

    Note: You will need to add column headers like i have in the attached Workbook..

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

  9. #9
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Looking to copy entire row if a cell value is greater than zero

    You're welcome and thanks for the rep!

    Maybe:

    Please Login or Register  to view this content.

  10. #10
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Looking to copy entire row if a cell value is greater than zero

    Thanks again for the rep!

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ 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. Delete entire row if any cell is greater than 25k
    By buwa84 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-12-2014, 01:26 PM
  2. Copy/Paste entire colum when a cell is greater then X
    By Orbital_Jesse in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-03-2014, 09:17 PM
  3. [SOLVED] sumif greater than copy this value, Comm % wants to copy value to other cell
    By Bitto in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 05-29-2013, 09:22 AM
  4. [SOLVED] Copy Entire row to new sheet if the value perticular column is greater than zero
    By yrk2k8 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-26-2013, 12:02 PM
  5. Copy if cell greater then zero
    By Bob@Sun in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-26-2009, 03:56 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