VBA: search multiple keywords in multiple columns, then move rows to second sheet

mglidden

New Member
Joined
Aug 12, 2021
Messages
1
Office Version
  1. 365
Platform
  1. Windows
Hello,
I am very new to VBA and my head is spinning trying to figure out what to do. Any help on my question is very much appreciated!

I have a sheet of customer info and am just looking to run a macro that searches for specific keywords in a couple of columns (an OR situation), and if any are found I would like the entire row in which the keywords are found to be cut, moved to a second sheet, then delete the blank row in the first sheet. Unfortunately, the sheet contains sensitive data so I can't really post the sheet as an example. I have found a few pieces that would work but I can't get them to all work together.

Example:
Search for several specified "Company Name" in both Columns E and G. If found, cut the row in which it is found and move it to Sheet2. Delete the blank row from Sheet1.
The sheets have thousands of lines so I need to search the entire sheet.

Again, any assistance is greatly appreciated as I am just spinning my wheels at this point. Please let me know what questions you have about what my vision is or how the data is set up.

Thank you!
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
Welcome to the MrExcel board!

Unfortunately, the sheet contains sensitive data so I can't really post the sheet as an example.
But you could mock up a small dummy sheet, post that (with XL2BB so we don't have to manually type it out) and explain again in relation to that sheet?
 
Upvote 0

Forum statistics

Threads
1,213,567
Messages
6,114,342
Members
448,570
Latest member
rik81h

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top