Created
March 29, 2017 20:01
-
-
Save danwagnerco/770ef3ec7d0b94c9e43a3ed2cef95e99 to your computer and use it in GitHub Desktop.
small adjustment
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'don't do this anymore: | |
DataBlock.SpecialCells(xlCellTypeVisible).Copy Destination:=Target.Cells(1, 1) | |
'instead try this: | |
Dim rngDestination As Range 'this should be way up at the top with all the other declarations | |
' ... all the other code | |
Set rngDestination = Target.Cells(1, 1) | |
DataBlock.SpecialCells(xlCellTypeVisible).Copy | |
rngDestination.PasteSpecial xlPasteType:=xlPasteValuesAndNumberFormats |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
After some googling, I figured this out: rngDestination.PasteSpecial Paste:=xlPasteValuesAndNumberFormats
Thanks again for the help!