In the process of converting an app from 10.2.5 to v100 SDK. Getting tons of these types of errors when my feature table queries are running:
ArcGIS Runtime Error Occurred. Set a breakpoint on C++ exceptions to see the original callstack and context for this error: Error Domain=com.esri.arcgis.runtime.error Code=2 "Invalid argument" UserInfo={NSLocalizedFailureReason=value's type doesn't match the vector's value type., NSLocalizedDescription=Invalid argument, Additional Message=value's type doesn't match the vector's value type.}
Error code 2 is sort of a generic invalid argument thing.
Can anyone tell me what vector this error is referring to?
Solved! Go to Solution.
Two properties make an error unique - the domain and the code.
Domains will commonly map to a specific error code enumeration.
For the domain "com.esri.arcgis.runtime.error" which equals `AGSErrorDomain`, the codes you look at are in the enumeration `AGSErrorCode`. Within that enumeration, the code 2 is:
`AGSErrorCodeCommonInvalidArgument = 2`. So you have an Invalid Argument somewhere.
In xcode, set a breakpoint on c++ exceptions. Then when that error occurs you can look at the callstack and see what you may be doing.
I would also make sure to address all the warnings in your project. It may be that you are putting a string in an array that takes a `AGSField` or something like that.
If that doesn't help, please consider providing us some code that reproduces the issue so that we can help diagnose what is going wrong.
Thanks
Two properties make an error unique - the domain and the code.
Domains will commonly map to a specific error code enumeration.
For the domain "com.esri.arcgis.runtime.error" which equals `AGSErrorDomain`, the codes you look at are in the enumeration `AGSErrorCode`. Within that enumeration, the code 2 is:
`AGSErrorCodeCommonInvalidArgument = 2`. So you have an Invalid Argument somewhere.
In xcode, set a breakpoint on c++ exceptions. Then when that error occurs you can look at the callstack and see what you may be doing.
I would also make sure to address all the warnings in your project. It may be that you are putting a string in an array that takes a `AGSField` or something like that.
If that doesn't help, please consider providing us some code that reproduces the issue so that we can help diagnose what is going wrong.
Thanks
I think the whole "vector" think was throwing me and leading me down a wild goose chase looking for some invalid geometry somewhere. Turns out I was using an old school array of field names in my AGSQueryParameters where clause instead of the newer array of AGSOrderBy objects.
I swear I'm up over 2000 changes converting this app from 10.2.5 to v100.
Thanks!