roxnoxsox
02-15-2016, 04:48 AM
I've used 'Record Macro' to record using the 'Remove Duplicates' button, which will delete rows in my data depending if the contents of column E, H, I, J, M, N and O are all the same.
The resultant macro is this:
ActiveSheet.Range("$A$1:$Q$3277").RemoveDuplicates Columns:=Array(5, 8, 9, 10, 13 _
, 14, 15), Header:=xlYes
Is it possible to adjust this to a dynamic range as my data will change every day (column order would still be the same). But I may have 5000 or more rows rather than 3277 as specified above. Would I just change this to: ("$A:$Q") or would that not work?
Many thanks for any suggestions! I'm new to using the Remove Duplicates function
The resultant macro is this:
ActiveSheet.Range("$A$1:$Q$3277").RemoveDuplicates Columns:=Array(5, 8, 9, 10, 13 _
, 14, 15), Header:=xlYes
Is it possible to adjust this to a dynamic range as my data will change every day (column order would still be the same). But I may have 5000 or more rows rather than 3277 as specified above. Would I just change this to: ("$A:$Q") or would that not work?
Many thanks for any suggestions! I'm new to using the Remove Duplicates function