
Originally Posted by
SamT
For your purposes
ValD = .Cells(I, 4).Text
Therefore
ObjDic.Item(Join(Array(.Cells(I, 1), .Cells(I, 2), .Cells(I, 3), ValD, ValE, .Cells(I, 6)), "/")) = Empty
Can be
ObjDic.Item(.Cells(I, 1) & .Cells(I, 2) & .Cells(I, 3) & .Cells(I, 4).Text & .Cells(I, 5).Text & .Cells(I, 6)) = True
And
If (ObjDic.exists(Join(Array(.Cells(I, 1), .Cells(I, 2), .Cells(I, 3), ValD, ValE, .Cells(I, 6)), "/"))) Then
.Cells(I, 7) = "V"
End If
Can Be
If ObjDic(.Cells(I, 1) & .Cells(I, 2) & .Cells(I, 3) & .Cells(I, 4).Text & .Cells(I, 5).Text & .Cells(I, 6)) Then .Cells(I, 7) = "V"
My personal preference would be
TestString = Cells(I, 1) & .Cells(I, 2) & .Cells(I, 3) & .Cells(I, 4).Text & .Cells(I, 5).Text & .Cells(I, 6)
ObjDic.Item(TestString) = True
But that is just me, I like to Uber_Comment my code with named variables.