<?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: Identify Tool - Silverlight Examples in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127075#M3179</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;the class is IdentifyResult not IdentifyResult(s) you added an "s" to the end. ^_^&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 06 Apr 2011 17:23:35 GMT</pubDate>
    <dc:creator>ChristopherHill</dc:creator>
    <dc:date>2011-04-06T17:23:35Z</dc:date>
    <item>
      <title>Identify Tool - Silverlight Examples</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127070#M3174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am new to developing in silverlight and I am trying to go through the examples found in the resource center. I copied and pasted the code for the identify tool into VS2010 and I am getting an error on building the project:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;"The type or namespace name 'IdentifyResults' could not be found (are you missing a using directive or an assembly reference?)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Did I miss a step somewhere? Am I missing a reference? I added all of the references that the example noted. Thanks for any input.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here are the two examples I was using:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Identify"&gt;http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Identify&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/help/index.html#/Identify_task/01660000001m000000/"&gt;http://help.arcgis.com/en/webapi/silverlight/help/index.html#/Identify_task/01660000001m000000/&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 14:36:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127070#M3174</guid>
      <dc:creator>BrandonIves</dc:creator>
      <dc:date>2011-04-06T14:36:22Z</dc:date>
    </item>
    <item>
      <title>Re: Identify Tool - Silverlight Examples</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127071#M3175</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am able to run the sample without any issues. What exactly is IdentifyResults? The only place it appears in the sample is args.IdentifyResults. I know there is IdentifyResult but I don't see IdentifyResults. Could you please attach your complete code here? Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 14:53:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127071#M3175</guid>
      <dc:creator>nakulmanocha</dc:creator>
      <dc:date>2011-04-06T14:53:02Z</dc:date>
    </item>
    <item>
      <title>Re: Identify Tool - Silverlight Examples</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127072#M3176</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Here is my code. Below I added an arrow to show the error.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;using System;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows.Controls;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows.Documents;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows.Ink;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows.Input;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows.Media;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows.Media.Animation;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Windows.Shapes;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;using ESRI.ArcGIS.Client;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using ESRI.ArcGIS.Client.Tasks;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using ESRI.ArcGIS.Client.Symbols;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;namespace IdentifyExpressionBlend&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; public partial class MainPage : UserControl&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;----------------&amp;gt; private List&amp;lt;IdentifyResults&amp;gt; _lastIdentifyResult;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; public MainPage()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // Required to initialize variables&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; InitializeComponent();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // Do identify when Map is clicked&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; private void MyMap_MouseClick(object sender, ESRI.ArcGIS.Client.Map.MouseEventArgs args)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // Show an icon at the identify location&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; GraphicsLayer graphicsLayer = MyMap.Layers["IdentifyIconGraphicsLayer"] as GraphicsLayer;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; graphicsLayer.ClearGraphics();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; ESRI.ArcGIS.Client.Graphic graphic = new ESRI.ArcGIS.Client.Graphic()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Geometry = args.MapPoint,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Symbol = IdentifyLocationSymbol&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; };&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; graphicsLayer.Graphics.Add(graphic);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Identify task initialization&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt; IdentifyTask identifyTask = new IdentifyTask("&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/" rel="nofollow" target="_blank"&gt;http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/&lt;/A&gt;&lt;SPAN&gt;" +&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; "Demographics/ESRI_Census_USA/MapServer");&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyTask.ExecuteCompleted += IdentifyTask_ExecuteCompleted;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyTask.Failed += IdentifyTask_Failed;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Initialize Identify parameters. Specify searching of all layers.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyParameters identifyParameters = new IdentifyParameters();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyParameters.LayerOption = LayerOption.all;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Pass current Map properties to identify parameters&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyParameters.MapExtent = MyMap.Extent;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyParameters.Width = (int)MyMap.ActualWidth;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyParameters.Height = (int)MyMap.ActualHeight;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Identify features at the click point&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyParameters.Geometry = args.MapPoint;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; identifyTask.ExecuteAsync(identifyParameters);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Populate ComboBox with results when identify is complete&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; private void IdentifyTask_ExecuteCompleted(object sender, IdentifyEventArgs args)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyComboBox.Items.Clear();&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Check for new results&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; if (args.IdentifyResults.Count &amp;gt; 0)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // Show ComboBox and attribuets DataGrid&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyResultsStackPanel.Visibility = Visibility.Visible;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Add results to ComboBox&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; foreach (IdentifyResult result in args.IdentifyResults)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; string title = string.Format("{0} ({1})", result.Value.ToString(), result.LayerName);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyComboBox.Items.Add(title);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Workaround for ComboBox bug&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyComboBox.UpdateLayout();&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Store the list of identify results&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; _lastIdentifyResult = args.IdentifyResults;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Initialize ComboBox and fire SelectionChanged&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyComboBox.SelectedIndex = 0;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; else&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // Hide ComboBox and attributes DataGrid and notify user&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyResultsStackPanel.Visibility = Visibility.Collapsed;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; MessageBox.Show("No features found");&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Show geometry and attributes of selected feature&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; void IdentifyComboBox_SelectionChanged(object sender, SelectionChangedEventArgs e)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // Clear previously selected feature from GraphicsLayer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; GraphicsLayer graphicsLayer = MyMap.Layers["ResultsGraphicsLayer"] as GraphicsLayer;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; graphicsLayer.ClearGraphics();&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Check that ComboBox has a selected item. Needed because SelectionChanged fires&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // when ComboBox.Clear is called.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; if (IdentifyComboBox.SelectedIndex &amp;gt; -1)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; // Update DataGrid with selected feature's attributes&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Graphic selectedFeature = _lastIdentifyResult[IdentifyComboBox.SelectedIndex].Feature;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; IdentifyDetailsDataGrid.ItemsSource = selectedFeature.Attributes;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Apply symbol and add selected feature to map&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; selectedFeature.Symbol = SelectedFeatureSymbol;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; graphicsLayer.Graphics.Add(selectedFeature);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; // Notify when identify fails&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; private void IdentifyTask_Failed(object sender, TaskFailedEventArgs args)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; MessageBox.Show("Identify failed: " + args.Error);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 15:13:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127072#M3176</guid>
      <dc:creator>BrandonIves</dc:creator>
      <dc:date>2011-04-06T15:13:46Z</dc:date>
    </item>
    <item>
      <title>Re: Identify Tool - Silverlight Examples</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127073#M3177</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The List class is available within System.Collections.Generic namespace. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You need to add the following as one of your using statements&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;using System.Collections.Generic;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 16:09:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127073#M3177</guid>
      <dc:creator>nakulmanocha</dc:creator>
      <dc:date>2011-04-06T16:09:12Z</dc:date>
    </item>
    <item>
      <title>Re: Identify Tool - Silverlight Examples</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127074#M3178</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I actually do have "using system.collections.generic;" as a using statement. Not sure why it didn't paste. I litterally copied and pasted the code and then added additional Using Statements. I took a screenshot to show the error.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 17:06:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127074#M3178</guid>
      <dc:creator>BrandonIves</dc:creator>
      <dc:date>2011-04-06T17:06:06Z</dc:date>
    </item>
    <item>
      <title>Re: Identify Tool - Silverlight Examples</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127075#M3179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;the class is IdentifyResult not IdentifyResult(s) you added an "s" to the end. ^_^&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 17:23:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127075#M3179</guid>
      <dc:creator>ChristopherHill</dc:creator>
      <dc:date>2011-04-06T17:23:35Z</dc:date>
    </item>
    <item>
      <title>Re: Identify Tool - Silverlight Examples</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127076#M3180</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Doh. Good eyes, thank you so much. Thanks to nmanocha also!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 17:26:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/identify-tool-silverlight-examples/m-p/127076#M3180</guid>
      <dc:creator>BrandonIves</dc:creator>
      <dc:date>2011-04-06T17:26:53Z</dc:date>
    </item>
  </channel>
</rss>

