<?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: FeatureDataGrid does not display rows with null values as of version 2.2 in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444727#M11524</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for answering Chris. Yes I'm loading data from a feature layer. DiffPct is an output field of the feature layer. it points to a sql server table and the sql data type of the DiffPct Column is float, null. Therefore the DiffPct column will always contain double values or null values. DiffPct is a calculated column (difference of two years values as percent). &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If the error message is due to the fact that some value is not null or not double, why did it all work with API version 2.1? I did not change the binding or anything that is used with the feature data grid.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 04 Aug 2011 13:53:55 GMT</pubDate>
    <dc:creator>stefanschlaefli</dc:creator>
    <dc:date>2011-08-04T13:53:55Z</dc:date>
    <item>
      <title>FeatureDataGrid does not display rows with null values as of version 2.2</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444725#M11522</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Since Version 2.2 the feature data grid does not display rows containing null values anymore. A Silverlight error is raised instead: &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Unhandled Error in Silverlight Application All rows must be of type 'System.Nullable`1[System.Double]' for the 'DiffPct' attribute.&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.Toolkit.FeatureDataGrid.AllAttributesMatch(PropertyInfo[] itemsSourceProperties, IDictionary`2 graphicAttributes)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.Toolkit.FeatureDataGrid.UpdateItemsSource(Object sender, NotifyCollectionChangedEventArgs e)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.Toolkit.FeatureDataGrid.Graphics_CollectionChanged(Object sender, NotifyCollectionChangedEventArgs e)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at System.Collections.Specialized.NotifyCollectionChangedEventHandler.Invoke(Object sender, NotifyCollectionChangedEventArgs e)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at System.Collections.ObjectModel.ObservableCollection`1.OnCollectionChanged(NotifyCollectionChangedEventArgs e)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at System.Collections.ObjectModel.ObservableCollection`1.InsertItem(Int32 index, T item)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.GraphicCollection.InsertItem(Int32 index, Graphic item)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at System.Collections.ObjectModel.Collection`1.Add(T item)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.FeatureLayer.addGraphic(Graphic g)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.FeatureLayer.task_QueryComplete(Object sender, QueryEventArgs args)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.Tasks.QueryTask.OnExecuteCompleted(QueryEventArgs args)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.Tasks.QueryTask.&amp;lt;&amp;gt;c__DisplayClass6.&amp;lt;request_Completed&amp;gt;b__4(FeatureSet fs, Exception ex)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at ESRI.ArcGIS.Client.Tasks.FeatureSet.&amp;lt;&amp;gt;c__DisplayClass2.&amp;lt;FromJsonAsync&amp;gt;b__0(Object s, RunWorkerCompletedEventArgs e)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at System.ComponentModel.BackgroundWorker.OnRunWorkerCompleted(RunWorkerCompletedEventArgs e)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; at System.ComponentModel.BackgroundWorker.&amp;lt;OnRun&amp;gt;b__1(Object state)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;An example of a typical Binding of type DataGridTextColumn is this one: &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;my:DataGridTextColumn Binding="{Binding DiffPct, TargetNullValue='0', StringFormat=\{0:P2\}}"&amp;nbsp; Width="130"&amp;nbsp; Header="% Change" CanUserSort="True" /&amp;gt;&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Prior to toolkit version 2.2 it would just work.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Jul 2011 08:41:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444725#M11522</guid>
      <dc:creator>stefanschlaefli</dc:creator>
      <dc:date>2011-07-29T08:41:14Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureDataGrid does not display rows with null values as of version 2.2</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444726#M11523</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Unhandled Error in Silverlight Application &lt;STRONG&gt;All rows must be of type 'System.Nullable`1[System.Double]' for the 'DiffPct'&lt;/STRONG&gt; attribute.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The error message you posted says that it expected all the values to be of type Nullable.Double but at least one of the rows in column DiffPct was of a different data type. Are you loading data from a binding to a featurelayer? if DiffPct is a double type then all values have to be of type double if it finds a row that has an integer then you will get the above exception you posted.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;you can use this public service to see that you can indeed have null data, but that is not the problem based on the error you provided. &lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/HomelandSecurity/operations/FeatureServer/0"&gt;http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/HomelandSecurity/operations/FeatureServer/0&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Jul 2011 23:23:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444726#M11523</guid>
      <dc:creator>ChristopherHill</dc:creator>
      <dc:date>2011-07-29T23:23:20Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureDataGrid does not display rows with null values as of version 2.2</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444727#M11524</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for answering Chris. Yes I'm loading data from a feature layer. DiffPct is an output field of the feature layer. it points to a sql server table and the sql data type of the DiffPct Column is float, null. Therefore the DiffPct column will always contain double values or null values. DiffPct is a calculated column (difference of two years values as percent). &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If the error message is due to the fact that some value is not null or not double, why did it all work with API version 2.1? I did not change the binding or anything that is used with the feature data grid.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 13:53:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444727#M11524</guid>
      <dc:creator>stefanschlaefli</dc:creator>
      <dc:date>2011-08-04T13:53:55Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureDataGrid does not display rows with null values as of version 2.2</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444728#M11525</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Have you tried loading the application with 2.1 again and seeing if the problem goes away to confirm that this is caused by 2.2? Have you tried looping through the graphics attributes and look at each Graphic.Attributes["DiffPct"].GetType() to determine that they are all of type double.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 15:37:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444728#M11525</guid>
      <dc:creator>ChristopherHill</dc:creator>
      <dc:date>2011-08-04T15:37:42Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureDataGrid does not display rows with null values as of version 2.2</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444729#M11526</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Yes, I rolled back to version 2.1 and the problem was gone. I didn't test every single graphic's DiffPct for it's type yet.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Aug 2011 06:11:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444729#M11526</guid>
      <dc:creator>stefanschlaefli</dc:creator>
      <dc:date>2011-08-05T06:11:03Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureDataGrid does not display rows with null values as of version 2.2</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444730#M11527</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am also experiencing the same problem.&amp;nbsp; I have loaded the graphics layer from MapIT and when I assign it to the data grid in code i.e.:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; MyDataGrid.GraphicsLayer = gLayer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;an exception is thrown detailing that not all rows are of the expected type (varies depending on the data received from MapIT).&amp;nbsp; It generally appears to be associated with columns that have NULL data.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If I drop back to 2.1 the problem goes away.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Aug 2011 02:21:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444730#M11527</guid>
      <dc:creator>ChrisLampe</dc:creator>
      <dc:date>2011-08-29T02:21:41Z</dc:date>
    </item>
    <item>
      <title>Re: FeatureDataGrid does not display rows with null values as of version 2.2</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444731#M11528</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Just for the record: this issue seems to have disappeared in API version 2.3.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jan 2012 06:29:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/featuredatagrid-does-not-display-rows-with-null/m-p/444731#M11528</guid>
      <dc:creator>stefanschlaefli</dc:creator>
      <dc:date>2012-01-05T06:29:18Z</dc:date>
    </item>
  </channel>
</rss>

