+ Reply to Thread
Results 1 to 3 of 3

Macro Formula needed to find a value and remember the row of the value, repeat

  1. #1
    Registered User
    Join Date
    07-30-2011
    Location
    Oklahom City, OK
    MS-Off Ver
    Excel 2003
    Posts
    2

    Macro Formula needed to find a value and remember the row of the value, repeat

    Hello all! I'm new to the forum and am a total nube when I comes to excel. I am trying to create a macro that is more than recording a few steps the macro recorder therefore I need some assistance writing the code. The below process currently take me a few hours to accomplish manually.

    1. First off is I pull an extract from another data base and copy it into excel. It is placed in Sheet 1 column A and has around 5000 rows.

    2. What I then do is have to parse the data into different sheets around 30 of them. This is where I need the macro

    3. The amount of data in each of the extracts is different therefore I can't set a specific row to row of data to copied and pasted in the macro.

    4. I need it to perform a search in Sheet 1 for a specific value in one of the rows, say 100D, then have the macro remember the row 100D was in

    5. Then perform another search for another value, say 200D, then have it remember the row it is in.

    6. Then have it copy the selection from row 100D was in through to the row the 200D minus 1 row therefore capturing all the data for the 100D portion of the extract.

    7. Then the data pasted is to the desired sheet2 (100D data)

    8. Then have it go back to Sheet 1 and delete the Selection that was pasted into Sheet2

    9. I will need to complete this transaction for 30 sheets of data. The next would be the same but searching for 200D, and then 300D and so on.

    I hope this makes sense and if it doesn’t please let me know.

    I have posted a file to at the following link:
    http://www.box.net/shared/35iosg3grvr9lqdqek19

    I hope this can be accomplished using a single macro and know that any direction is greatly appreciated.
    Last edited by 66Deuce; 07-31-2011 at 10:19 AM.

  2. #2
    Valued Forum Contributor Charles's Avatar
    Join Date
    02-10-2004
    Location
    Biloxi
    MS-Off Ver
    Windows 7, Excel 2003,2007 & Mac2011
    Posts
    845

    Re: Macro Assistance

    66Deuce,


    Welcome to the forum.

    When I looked at your workbook I did not see as your example "100D" in the main sheet. I did see "P70100D". Is this what you are looking for?
    Charles

    There are other ways to do this, this is but 1 !
    Be Sure you thank those who helped.
    IF YOU'RE SATISFIED BY ANY MEMBERS RESPONSE TO YOUR ISSUE PLEASE USE THE STAR ICON AT THE BOTTOM LEFT OF THE POST UNDER THEIR NAME.

  3. #3
    Registered User
    Join Date
    07-30-2011
    Location
    Oklahom City, OK
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: Macro Assistance

    Yes it is. But rather than having to seach by the full P70100D I've been just using 100D. If you look on the tabs on the bottom you will see the names 100D, 200D and so on. What I need it to do is copy all the data from the row the 100D is in to the row before the 200D, it is full of asteriks. Once copied and pasted in the tab for 100D on the 3rd row due to loaded information it needs to be deleted on the A10000D tab. Then the process needs to be the same for the other tabs. Thanks for your help.

+ 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