<?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 Re: AGSQueryTaskDelegate not firing in ArcGIS Runtime SDK for iOS Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsquerytaskdelegate-not-firing/m-p/153447#M1409</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;sorry if i'm misunderstand your question but you'll need to set up a query to excecute your query task. Here is a simplified example.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;

//alongside your agsquerytask set up an agsquery
@property(nonatomic, strong)AGSQueryTask* queryTask;
@property(nonatomic, strong)AGSQuery* query;

&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;after setting up that query, maybe in viewDidLoad or wherever you'd like the query to happen you'll need to do something like this.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;

//set up query task
self.queryTask = [AGSQueryTask queryTaskWithURL:[NSURL URLWithString: "your URL"]]; 
self.queryTask.delegate = self; 

//set up query and options
self.query = [AGSQuery query]; 
self.query.outFields = [NSArray arrayWithObjects: "*", nil]; 
self.query.where = @"1=1";

//execute querytask with query 
[self.queryTask executeWithQuery: self.query];


&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;with that in place you should reach &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;queryTask operation didExecuteWithFeatureSetResult retreivedFeatureSet&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;where you will have access to whatever was returned from your query.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this helps.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 11 Dec 2021 08:12:48 GMT</pubDate>
    <dc:creator>ChristopherBarger</dc:creator>
    <dc:date>2021-12-11T08:12:48Z</dc:date>
    <item>
      <title>AGSQueryTaskDelegate not firing</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsquerytaskdelegate-not-firing/m-p/153446#M1408</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am trying to query all the features from my database through a querytask, but no delegate methods are being invoked.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I created a strong property AGSQueryTask :&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;@interface MyClass : NSObject &amp;lt;AGSQueryTaskDelegate&amp;gt; &lt;/PRE&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;@property(nonatomic, strong)AGSQueryTask* queryTask;&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;set the delegate as self:&lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt; self.queryTask.delegate = self;&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;but nothing happens.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Ideas?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Dec 2013 06:26:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsquerytaskdelegate-not-firing/m-p/153446#M1408</guid>
      <dc:creator>NicoleDe_La_Feld</dc:creator>
      <dc:date>2013-12-06T06:26:56Z</dc:date>
    </item>
    <item>
      <title>Re: AGSQueryTaskDelegate not firing</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsquerytaskdelegate-not-firing/m-p/153447#M1409</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;sorry if i'm misunderstand your question but you'll need to set up a query to excecute your query task. Here is a simplified example.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;

//alongside your agsquerytask set up an agsquery
@property(nonatomic, strong)AGSQueryTask* queryTask;
@property(nonatomic, strong)AGSQuery* query;

&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;after setting up that query, maybe in viewDidLoad or wherever you'd like the query to happen you'll need to do something like this.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;

//set up query task
self.queryTask = [AGSQueryTask queryTaskWithURL:[NSURL URLWithString: "your URL"]]; 
self.queryTask.delegate = self; 

//set up query and options
self.query = [AGSQuery query]; 
self.query.outFields = [NSArray arrayWithObjects: "*", nil]; 
self.query.where = @"1=1";

//execute querytask with query 
[self.queryTask executeWithQuery: self.query];


&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;with that in place you should reach &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;queryTask operation didExecuteWithFeatureSetResult retreivedFeatureSet&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;where you will have access to whatever was returned from your query.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this helps.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 08:12:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsquerytaskdelegate-not-firing/m-p/153447#M1409</guid>
      <dc:creator>ChristopherBarger</dc:creator>
      <dc:date>2021-12-11T08:12:48Z</dc:date>
    </item>
    <item>
      <title>Re: AGSQueryTaskDelegate not firing</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsquerytaskdelegate-not-firing/m-p/153448#M1410</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thank you for your answer. I already did what you say and it's right. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The problem was that I accidentally deallocated the queryTask before the operation was completed.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Dec 2013 06:31:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsquerytaskdelegate-not-firing/m-p/153448#M1410</guid>
      <dc:creator>NicoleDe_La_Feld</dc:creator>
      <dc:date>2013-12-10T06:31:56Z</dc:date>
    </item>
  </channel>
</rss>

