Easier Way than Filter/Copy/Paste

helpexcel

Well-known Member
Joined
Oct 21, 2009
Messages
656
I have a macro that filters data based on column A, then copies A2:Dlastrow to another worksheet. Works fine, but was wondering if there is a way to look at the values in column A and then copy/paste the rows with the same values to a sheet with the same name as the values?
So in this example, it would copy each row with Apple to the sheet named Apple. thanks!

FruitCostInventoryType
Apple13Fuji
Apple23Pink Lady
Apple33Fuji
Apple43Fuji
Apple53Pink Lady
Apple63Pink Lady
Apple73Pink Lady
Apple83Granny Smith
Apple93Granny Smith
Apple13Granny Smith
Pear110Bartlett
Pear210Concord
Pear310Concord
Pear410Bartlett
Pear510Anjou
Pear610Anjou
Pear710Anjou
Pear810Bartlett
Pear910Concord
Orange15Navel
Orange25Navel
Orange35Blood
Orange45Blood
Orange55Mandarin
Orange65Mandarin
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Yes, that's easy! Provide code

Can you just use pivot tables on separate sheets, each with their own filter for column A?
 
Upvote 0
Or just using an advanced filter …​
 
Upvote 0
I don't want to use pivot tables because they can mess up the additional calculations I have the the Apple sheet. I'm basically using advanced filter now with the code, where it filters and then copies visable cells. I was trying to see if there was a quicker, more efficient way of writing the code. thanks!
 
Upvote 0
As using an advanced filter should be an efficient way with a pretty good coding so at least post your code via the VBA icon​
with the necessary elaboration in order there is nothin' to guess or link a workbook sample on a files host website like Dropbox …​
 
Upvote 0

Forum statistics

Threads
1,214,978
Messages
6,122,549
Members
449,089
Latest member
davidcom

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