From: Dana DeLouis on 25 Apr 2010 12:12
Hi. Just some more options.
There are many variations, even along the following general ideas.
Assuming A1 is a database heading, this gets data starting in A2, and
places unique data in C2.
Unique = Union(GetColumn([A2]).Value)
[C2].Resize(UBound(Unique)) = T1(Unique)
'// Library Stuff:
'// UnSorted Union
Dim D, Obj
Const Dummy As Long = 1
Set D = CreateObject("Scripting.Dictionary")
On Error Resume Next
For Each Obj In v
D.Add Obj, Dummy
'Note: Moving Keys out makes Index 0-based
'I prefer 1-base. Adjust other code if not used
Union = T2(D.keys)
Function GetColumn(Top) As Range
Set GetColumn = Range(Top, Cells(Rows.Count, Top.Column).End(xlUp))
T1 = WorksheetFunction.Transpose(m)
T2 = .Transpose(.Transpose(m))
= = = = = = =
On 4/24/2010 3:04 AM, Andri wrote:
> Dear Experts,
> Please help related to the above subject.
> From this discussion, got the following formula which is work well and
> faster for small of database.
> where $G$1, the first row of DATA.
> how to convert it to VBA as this time i have a huge database.
> for Tab Data, Advanced, Unique Record only (works well also, but i need the
> basically we would like to do similar like this:
> Data Sample
> Vendor Name
> the Result of Unique Vendor will be