I have a field that contains alpha, numerican and mixed codes. It's been suggested that I filter out all the numeric codes from my query. To test for this I am using a cint() function to convert the value to a number if it is numeric, but this produces an #Error when the value is not numeric. I expected this and planned to get around it by using the IsError function,
Code:
IsError(CInt([diagnosiscD]))
eventually planning on substituting an alternate value via the IIF() function or the error code.
Code:
IIf(IsError(Cint([diagnosiscD])),0,IsNumeric(Cint([diagnosiscD])))
Well, even though it is an error, I still get the #Error code instead a True or False from the IsError function. As long a I have an error code in that field and can Filter for True or False.
Long story short? Why isn't the IsError function detecting the error? or should I go about this differently?
p.s. I searched the site for IsError() and a saw a few others had similar problems with IIF(IsError(... scenario, but none of those solutions seemed to apply to my example.