Paste Values Filtered Data

AussieVic

Active Member
Joined
Jan 9, 2009
Messages
364
Hi, is there anyway to paste values filtered data other than unfiltering data and going through the cells one by one as i dont want to paste values all cells. At the moment i am getting an error when the data is filtered and i select the cells i want to paste values.
 

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.
Where do you want to paste it to?

Copying filtered data and pasting it to another location is straightforward, since Excel recognizes the filter and copies only the visible cells. When you paste it, it converts the non-contiguous range it copied to a contiguous range.

However, if you're trying to paste it back over itself then it's not so easy. In fact, I don't know a way without using VBA, but that doesn't mean one doesn't exist.

Have I understood your problem?
 
Upvote 0
Pre-empting your answer to the above as "yes, I want to paste the values of a filtered list on top of themselves", try:

Code:
Sub PasteValuesFiltered()
Dim rngCopy, rngC As Range
    Set rngCopy = Range("A2:A10").SpecialCells(xlCellTypeVisible)
For Each rngC In rngCopy
    rngC.Value = rngC.Value
Next rngC
End Sub
 
Upvote 0
Yard you rock, this is exactly what i required, i knew there must have been a VBA answer to this, a lot of people said it was not possible, you proved them wrong. :)


Pre-empting your answer to the above as "yes, I want to paste the values of a filtered list on top of themselves", try:

Code:
Sub PasteValuesFiltered()
Dim rngCopy, rngC As Range
    Set rngCopy = Range("A2:A10").SpecialCells(xlCellTypeVisible)
For Each rngC In rngCopy
    rngC.Value = rngC.Value
Next rngC
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,911
Messages
6,122,195
Members
449,072
Latest member
DW Draft

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