List all instances of a value from a list of mixed values to separate tab

clamont7

New Member
Joined
Aug 31, 2018
Messages
15
I have a column of data on a tab called "Data Dump" in column A. The column contains 5 different product codes. I'm trying to do something along the lines of:

If A2 on the "Data Dump" tab equals "S-7", copy and paste A2, B2, C2, and D2 to a new tab called "S-7" starting with cell A9.
Do this the whole way down the column on the "Data Dump" tab for "S-7"

Ex.
Data Dump New Tab
S-7 S-7
S-7 S-7
S-7 S-7
T-C S-7
T-C S-7
W-1
S-7
S-7

I can't seem to get them listed like above (without empty spaces between matches). Any help would be greatly appreciated!
 
Your assumption was right about column A having additional data. I just didn't recognize it because the cell contents were blank, they had formulas in them, which was throwing off the code. Thanks again everyone for all the help!
 
Upvote 0

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.

Forum statistics

Threads
1,223,886
Messages
6,175,196
Members
452,616
Latest member
intern444

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