Select to view content in your preferred language

Attachments from map services

1472
2
Jump to solution
09-07-2016 10:46 AM
MarkCederholm
Frequent Contributor

Is there a way to query attachments from a map service (as opposed to a feature service)?  I can create and initialize a ServiceFeatureTable OK, but when I try to query attachments, I get the dreaded "Row not found" exception.  I can get to the attachments directly through REST calls, so I know it's not a data or service issue.

0 Kudos
1 Solution

Accepted Solutions
Espen_RøvikLarsen
Occasional Contributor

I had this problem too. I would get the same error when calling "QueryAttachmentsAsync". Solution was to call "QueryAsync" first getting the feature itself (it has something to do with internal caching in the API I guess).

View solution in original post

0 Kudos
2 Replies
Espen_RøvikLarsen
Occasional Contributor

I had this problem too. I would get the same error when calling "QueryAttachmentsAsync". Solution was to call "QueryAsync" first getting the feature itself (it has something to do with internal caching in the API I guess).

0 Kudos
MarkCederholm
Frequent Contributor

That did the trick.  Normally I query features in a separate block of code, and the memory context must make a difference.  Thanks for the tip!

0 Kudos