a couple of things I see. There is a . instead of a , between the 4 and "e" in the first cell reference.
Also you should reference the columns by number and not character so you'd use
Code:If Ucase(aSheet.Cells(4, 5)).value = "ABCD" AND if aSheet.Cells(i,4) <> "" And dic.Exists((aSheet.Cells(i,4)) then MsgBox ("ABCD ORG NOT CONSISTENT" ) Exit Sub




Reply With Quote