Quantcast
Channel: Excel Help Forum - Excel Programming / VBA / Macros
Viewing all articles
Browse latest Browse all 50327

How to Remove Duplicates After Each Auto Refresh from External Connection?

$
0
0
Does anyone have any suggestions on how to do this better? I am currently running this macro when the data changes. If not, is there a way to specify the sheet without selecting it? In other words, what can I replace ActiveSheet.Range with so I do not have to change to that sheet in the macro? Any help is greatly appreciated as I have searched several hours for this.

Code:

Sub DUPLICATES()
' DUPLICATES Macro
'
    Sheets("RL").Select
    ActiveSheet.Range("Table_ExternalData_119[#All]").RemoveDuplicates Columns:=2 _
        , Header:=xlYes
    Sheets("COVER").Select
End Sub


Viewing all articles
Browse latest Browse all 50327

Latest Images

Trending Articles



Latest Images