I'm having a problem with DCount in VBA.
I'm trying to fill an array with values calculated by Dcount. One of the criteria I use in the Dcount I want to get from a different array, this gives the problem:
Dim i As Integer
For i = 0 To (intNumberOfSplitterboxes - 1)
Dim arrFreeSingleModePorts(243) As Variant
arrFreeSingleModePorts(i) =
DCount("ID", "SplitterboxPorts", _
"SplitterboxID=i AND Mode='SingleMode' AND IsNull(DevicePortID) AND IsNull(SplitterboxPortID)")
Next
I get error 2471