Filter row to a new worksheet

K

Khalil Handal

Hi to All
A workbook has several sheets. Colomn CN in Sheet3 has different symbols
starting g0, g1, g1a, g1b,..., until the code g12b.
Lines 1 to 13 are headers. What VBA code do I need to filter these lines so
that it copies all the lines with similar code to a new sheet in the same
workbook with the headings.

for example:
filter all rows with value (g2b) and copy them into a new sheet named (g2b)
in the same workbook including the heading lines. I hope that I xplained
myself clearly!
 
D

Don Guillett

Within a for each looping macro for each item in the list, You could use
data>autofilter>filter on the code>add sheet with that item name and then
copy the visible cells to that newly created sheet. Then do the next one.
Record the 1st one to see what is happening. Should get you started.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top