+ Reply to Thread
Results 1 to 5 of 5

Cut and paste from one worksheet to another

  1. #1
    Registered User
    Join Date
    10-18-2007
    Posts
    89

    Cut and paste from one worksheet to another

    I have a list of inventory and I want to paste the rows that contain the word "Buy" to a new worksheet titled "Order". When I run the macro I end up with a 0 in every cell from A6 to IV6. This is what I have so far.

    Thanks in advance for any help.

    Please Login or Register  to view this content.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Cut and paste from one worksheet to another

    Use this instead:
    Please Login or Register  to view this content.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    10-18-2007
    Posts
    89

    Re: Cut and paste from one worksheet to another

    That works great but it only Copies & Pastes the first instance of "Buy" and then stops.
    I am not sure, but I think I need to loop it some how. Could you help with that?

    Thanks again.
    -James

  4. #4
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Cut and paste from one worksheet to another

    It is looping through all the valid ranges in column I. On the sheet I had to mockup to test it (you didn't upload a sheet to test on) it works as expected.

    Post up your sample sheet, and be sure to try the macro again on the sample sheet just before you upload it.

    If it's not really obvious, I suppose it wouldn't hurt to mockup a "results" page too so we can see the goal. It's usually obvious, but sometime not.

  5. #5
    Registered User
    Join Date
    10-18-2007
    Posts
    89

    Re: Cut and paste from one worksheet to another

    Sorry I should have thought to include a sample. This is not an exact copy as my original links to other sheets. I have attached it here.
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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