seeing the entire code would be of more help.
first four variables are added for testing purposes based on my assumptions below.
Endlign = 10
C_Tot = 5
C_Key = 4
C_Ids = 1
adr1, adr2 and crit are string variables. declare them in the code.
crit = """""" = nullstring
Sub x()
Endlign = 10
C_Tot = 5
C_Key = 4
C_Ids = 1
adr1 = Range(Cells(2, C_Ids), Cells(Endlign, C_Ids)).Address(0, 0)
adr2 = Range(Cells(2, C_Key), Cells(Endlign, C_Key)).Address(0, 0)
crit = """"""
For i = 2 To Endlign
If Cells(i, C_Key) = "" Then
Cells(i, C_Tot) = ""
Else
My_Count = Evaluate("=SumProduct(--(" & adr1 & "=" & Cells(i, C_Ids) & "),--(" & adr2 & "<>" & crit & "))")
If My_Count > 0 Then
Cells(i, C_Tot) = My_Count
Else
Cells(i, C_Tot) = "Not counting"
End If
End If
Next i
End Sub