+ Reply to Thread
Results 1 to 7 of 7

How to move a whole row into a new sheet, when Column E has certain words in a sentance.

  1. #1
    Registered User
    Join Date
    10-16-2012
    Location
    Milton Keynes
    MS-Off Ver
    Excel 2010
    Posts
    4

    How to move a whole row into a new sheet, when Column E has certain words in a sentance.

    Hi All,

    I am new to this and I have been searching for a few days now to find a Macro that will look for a group of words which are basically a variation of the word Hardware. And return the whole row into another sheet in the book? So far I have found some code that I think should work, however it is not my code and I have tried to ammend the code to work for my scenario.

    Does anyone have any suggestions on how to fix this to do what I have just explained? I have attached the sample Workbook and it has the current Macro code built in (the one that doesnt quite work) Currently it copies the top line to sheet two but does not search for the words and return the row in to sheet 2. The list of words I am looking to search for are on sheet3.

    Thanks anyone for help on this problem

    Kindest Regards

    Ian.Sample Report with Macro.xlsx

  2. #2
    Registered User
    Join Date
    10-17-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    39

    Re: How to move a whole row into a new sheet, when Column E has certain words in a sentanc

    Try using the code below. Make sure it's not in a worksheet or workbook module. I'm not sure what column you want to search or what sheet you want to copy to but you can change that by making changes to the last if statement.

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    10-16-2012
    Location
    Milton Keynes
    MS-Off Ver
    Excel 2010
    Posts
    4

    Re: How to move a whole row into a new sheet, when Column E has certain words in a sentanc

    Hi Snax,

    Thank you for the above, I think I have not explained what I need very well sorry about that, in the sample sheet I provided there is a list of words I need to search for in 'sheet3', and the column I need to search for these words is column E, then if the word does appear I need to take the whole row and place it in 'sheet2' in the workbook.

    Thank you very much for help on this, you are a life saver, my brain was frying!

    Kind Regards

    Ian

  4. #4
    Registered User
    Join Date
    10-17-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    39

    Re: How to move a whole row into a new sheet, when Column E has certain words in a sentanc

    Ian,

    Try the code below. I think it does what you need it to do. Just make sure that there are no blank rows on the third sheet or on the first sheet. Also, you'll need to put some sort of text in cell A1 on the third sheet.

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    10-16-2012
    Location
    Milton Keynes
    MS-Off Ver
    Excel 2010
    Posts
    4

    Re: How to move a whole row into a new sheet, when Column E has certain words in a sentanc

    Hi Snax,

    You are are a saviour, and it seems to work on the sample sheet but not in the full document? what variables should I adjust to make it work on any report sheet I have, as long as the columns and sheets stay the same? I have attached my actual workbook with the data in, I hope it makes sense to you why this is not picking up anything? I have randomly placed the words from the search list in 'sheet3' in Column E to see if it will pick it up but it doesnt? Am I missing a vital step? I have attached the real data with the Macro in it.

    Kindest RegardsChalkiesQuoteReportIssue.xlsm

    Ian.

  6. #6
    Registered User
    Join Date
    10-17-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    39

    Re: How to move a whole row into a new sheet, when Column E has certain words in a sentanc

    Sorry about that. I didn't realize that I had a few things crossed up on the other file because I was getting the results I was looking for incorrectly. The code below worked on the file you attached.

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    10-16-2012
    Location
    Milton Keynes
    MS-Off Ver
    Excel 2010
    Posts
    4

    Re: How to move a whole row into a new sheet, when Column E has certain words in a sentanc

    Hi Snax,

    That works perfect, thank you so much. I can now apply this to each report every month.

    Have a great day.

    Kindest Regards
    Ian

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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