<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic IdentifyTask timing issue - iOS in ArcGIS Runtime SDK for iOS Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifytask-timing-issue-ios/m-p/229395#M2105</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm using IdentifyTask to test for parcel content being present in an existing app, specifically as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I set the parameters &lt;SPAN style="color: #000000;"&gt;in ParcelController, then&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #3d1d81;"&gt;NSLog&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;(&lt;/SPAN&gt;@"Fetching Parcels with params"&lt;SPAN style="color: #000000;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #3d1d81;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [&lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;identifyTask&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; &lt;/SPAN&gt;executeWithParameters&lt;SPAN style="color: #000000;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;params&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;];&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #3d1d81;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;Then test results in ParcelDelegate upon completion &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;-(&lt;SPAN style="color: #bb2ca2;"&gt;void&lt;/SPAN&gt;)identifyTask:(&lt;SPAN style="color: #703daa;"&gt;AGSIdentifyTask&lt;/SPAN&gt; *)identifyTask operation:(&lt;SPAN style="color: #703daa;"&gt;NSOperation&lt;/SPAN&gt; *)op didExecuteWithIdentifyResults:(&lt;SPAN style="color: #703daa;"&gt;NSArray&lt;/SPAN&gt; *)results&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;{&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #3d1d81;"&gt;NSLog&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;(&lt;/SPAN&gt;@"Results.count: %li"&lt;SPAN style="color: #000000;"&gt;, results.&lt;/SPAN&gt;&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;);&amp;nbsp; // this is the parcel count&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #bb2ca2;"&gt;if&lt;/SPAN&gt; (results.&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt; &amp;gt; &lt;SPAN style="color: #272ad8;"&gt;0&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;SPAN style="color: #000000; font-size: 11px; font-family: Menlo;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 14px; color: #000000;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 14px; color: #000000;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;This works fine, but now I'd like to be able to provide the user a warning if no content is present, this from the MapViewController.&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;I added the following at the ParcelDelegate:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;-(&lt;SPAN style="color: #bb2ca2;"&gt;void&lt;/SPAN&gt;)identifyTask:(&lt;SPAN style="color: #703daa;"&gt;AGSIdentifyTask&lt;/SPAN&gt; *)identifyTask operation:(&lt;SPAN style="color: #703daa;"&gt;NSOperation&lt;/SPAN&gt; *)op didExecuteWithIdentifyResults:(&lt;SPAN style="color: #703daa;"&gt;NSArray&lt;/SPAN&gt; *)results&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;{&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;contentPresent&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="color: #bb2ca2;"&gt;NO&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #3d1d81;"&gt;NSLog&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;(&lt;/SPAN&gt;@"Results.count: %li"&lt;SPAN style="color: #000000;"&gt;, results.&lt;/SPAN&gt;&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #bb2ca2;"&gt;if&lt;/SPAN&gt; (results.&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt; &amp;gt; &lt;SPAN style="color: #272ad8;"&gt;0&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;contentPresent&lt;SPAN style="color: #000000;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="color: #bb2ca2;"&gt;YES&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;At the MapViewController I use contentPresent to alert the user if no content is available.&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;The problem is that contentPresent never sets as true, there appears to be a thread issue in which &lt;/SPAN&gt;&lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults:&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; takes a while to execute, and my if(!contentPresent) test executes before &lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults: &lt;/SPAN&gt;is invoked.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;So I added another flag in &lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults:&lt;/SPAN&gt; (contentChecked) to allow the MapViewController to wait until &lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults:&lt;/SPAN&gt; is invoked.&amp;nbsp; That test simply results in the system getting stuck in a endless while(!contentChecked) loop.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;I inherited this app and am by no means an expert in iOS or Objective-C.&amp;nbsp; I'm using global variables for contentChecked and contentPresent and have confirmed that they are indeed visible and addressable across all areas.&amp;nbsp; It appears that the identifyTask is not executing, but only if I try to pass information out of it using the global variables.&amp;nbsp; When I remark my changes out, it all works just fine.&amp;nbsp; Is there a thread issue with identifyTask I'm missing?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;Any ideas or suggestions are most welcome!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;Chuck &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 13 Nov 2015 20:22:29 GMT</pubDate>
    <dc:creator>ChuckBenton</dc:creator>
    <dc:date>2015-11-13T20:22:29Z</dc:date>
    <item>
      <title>IdentifyTask timing issue - iOS</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifytask-timing-issue-ios/m-p/229395#M2105</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm using IdentifyTask to test for parcel content being present in an existing app, specifically as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I set the parameters &lt;SPAN style="color: #000000;"&gt;in ParcelController, then&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #3d1d81;"&gt;NSLog&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;(&lt;/SPAN&gt;@"Fetching Parcels with params"&lt;SPAN style="color: #000000;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #3d1d81;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [&lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;identifyTask&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; &lt;/SPAN&gt;executeWithParameters&lt;SPAN style="color: #000000;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;params&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;];&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #3d1d81;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;Then test results in ParcelDelegate upon completion &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;-(&lt;SPAN style="color: #bb2ca2;"&gt;void&lt;/SPAN&gt;)identifyTask:(&lt;SPAN style="color: #703daa;"&gt;AGSIdentifyTask&lt;/SPAN&gt; *)identifyTask operation:(&lt;SPAN style="color: #703daa;"&gt;NSOperation&lt;/SPAN&gt; *)op didExecuteWithIdentifyResults:(&lt;SPAN style="color: #703daa;"&gt;NSArray&lt;/SPAN&gt; *)results&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;{&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #3d1d81;"&gt;NSLog&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;(&lt;/SPAN&gt;@"Results.count: %li"&lt;SPAN style="color: #000000;"&gt;, results.&lt;/SPAN&gt;&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;);&amp;nbsp; // this is the parcel count&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #bb2ca2;"&gt;if&lt;/SPAN&gt; (results.&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt; &amp;gt; &lt;SPAN style="color: #272ad8;"&gt;0&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;SPAN style="color: #000000; font-size: 11px; font-family: Menlo;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 14px; color: #000000;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 14px; color: #000000;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #4f8187;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;This works fine, but now I'd like to be able to provide the user a warning if no content is present, this from the MapViewController.&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;I added the following at the ParcelDelegate:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;-(&lt;SPAN style="color: #bb2ca2;"&gt;void&lt;/SPAN&gt;)identifyTask:(&lt;SPAN style="color: #703daa;"&gt;AGSIdentifyTask&lt;/SPAN&gt; *)identifyTask operation:(&lt;SPAN style="color: #703daa;"&gt;NSOperation&lt;/SPAN&gt; *)op didExecuteWithIdentifyResults:(&lt;SPAN style="color: #703daa;"&gt;NSArray&lt;/SPAN&gt; *)results&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;{&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;contentPresent&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="color: #bb2ca2;"&gt;NO&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #3d1d81;"&gt;NSLog&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;(&lt;/SPAN&gt;@"Results.count: %li"&lt;SPAN style="color: #000000;"&gt;, results.&lt;/SPAN&gt;&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #bb2ca2;"&gt;if&lt;/SPAN&gt; (results.&lt;SPAN style="color: #703daa;"&gt;count&lt;/SPAN&gt; &amp;gt; &lt;SPAN style="color: #272ad8;"&gt;0&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;SPAN style="color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;contentPresent&lt;SPAN style="color: #000000;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="color: #bb2ca2;"&gt;YES&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;At the MapViewController I use contentPresent to alert the user if no content is available.&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;The problem is that contentPresent never sets as true, there appears to be a thread issue in which &lt;/SPAN&gt;&lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults:&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; takes a while to execute, and my if(!contentPresent) test executes before &lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults: &lt;/SPAN&gt;is invoked.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;So I added another flag in &lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults:&lt;/SPAN&gt; (contentChecked) to allow the MapViewController to wait until &lt;SPAN style="font-family: Menlo; font-size: 11px;"&gt;didExecuteWithIdentifyResults:&lt;/SPAN&gt; is invoked.&amp;nbsp; That test simply results in the system getting stuck in a endless while(!contentChecked) loop.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;I inherited this app and am by no means an expert in iOS or Objective-C.&amp;nbsp; I'm using global variables for contentChecked and contentPresent and have confirmed that they are indeed visible and addressable across all areas.&amp;nbsp; It appears that the identifyTask is not executing, but only if I try to pass information out of it using the global variables.&amp;nbsp; When I remark my changes out, it all works just fine.&amp;nbsp; Is there a thread issue with identifyTask I'm missing?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;Any ideas or suggestions are most welcome!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;Chuck &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Nov 2015 20:22:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifytask-timing-issue-ios/m-p/229395#M2105</guid>
      <dc:creator>ChuckBenton</dc:creator>
      <dc:date>2015-11-13T20:22:29Z</dc:date>
    </item>
    <item>
      <title>Re: IdentifyTask timing issue - iOS</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifytask-timing-issue-ios/m-p/229396#M2106</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A better approach might be as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;-(&lt;SPAN style="font-style: inherit; font-family: inherit; color: #bb2ca2;"&gt;void&lt;/SPAN&gt;)identifyTask:(&lt;SPAN style="font-style: inherit; font-family: inherit; color: #703daa;"&gt;AGSIdentifyTask&lt;/SPAN&gt; *)identifyTask operation:(&lt;SPAN style="font-style: inherit; font-family: inherit; color: #703daa;"&gt;NSOperation&lt;/SPAN&gt; *)op didExecuteWithIdentifyResults:(&lt;SPAN style="font-style: inherit; font-family: inherit; color: #703daa;"&gt;NSArray&lt;/SPAN&gt; *)results&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;{&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #2873ee;"&gt;//instead of using the flag&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #2873ee;"&gt;//&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #2873ee;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;contentPresent&lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;NO&lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #2873ee;"&gt;//call the method to alert the user&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [self alertUser];&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #3d1d81;"&gt;NSLog&lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;(&lt;/SPAN&gt;@"Results.count: %li"&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;, results.&lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #703daa;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-style: inherit; font-family: inherit; color: #bb2ca2;"&gt;if&lt;/SPAN&gt; (results.&lt;SPAN style="font-style: inherit; font-family: inherit; color: #703daa;"&gt;count&lt;/SPAN&gt; &amp;gt; &lt;SPAN style="font-style: inherit; font-family: inherit; color: #272ad8;"&gt;0&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #2873ee;"&gt;//instead of this&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;SPAN style="color: #2873ee;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //&lt;/SPAN&gt;contentPresent&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;YES&lt;/SPAN&gt;&lt;SPAN style="font-style: inherit; font-family: inherit;"&gt;;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #2873ee;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //call a different method or add code inline, to process the results&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [self processResults:results];&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;SPAN style="font-style: inherit; font-family: inherit; color: #000000;"&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;-(void)alertUser {&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //alert the user for no results&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;}&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;-(void)processResults:(NSArray*)results {&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //process the results&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #4f8187;"&gt;}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Nov 2015 00:02:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifytask-timing-issue-ios/m-p/229396#M2106</guid>
      <dc:creator>GagandeepSingh</dc:creator>
      <dc:date>2015-11-18T00:02:00Z</dc:date>
    </item>
  </channel>
</rss>

