<?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: Is DictionarySymbolPreview sample broken? in ArcGIS Pro SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016570#M6000</link>
    <description>&lt;P&gt;Starting with a fresh MilitaryOverlay.aprx from the zip file, I see a &lt;FONT color="#FF0000"&gt;!&lt;/FONT&gt;&amp;nbsp;next to the stylx:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="KirkKuykendall1_0-1610569829795.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/3791i9643A5544091B8BC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KirkKuykendall1_0-1610569829795.png" alt="KirkKuykendall1_0-1610569829795.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I clicked and browsed for:&lt;/P&gt;&lt;P&gt;"C:\Program Files\ArcGIS\Pro\Resources\Dictionaries\mil2525d\mil2525d.stylx"&lt;/P&gt;&lt;P&gt;and the ! cleared.&lt;/P&gt;&lt;P&gt;Still get null ref exception though.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 13 Jan 2021 20:31:39 GMT</pubDate>
    <dc:creator>KirkKuykendall1</dc:creator>
    <dc:date>2021-01-13T20:31:39Z</dc:date>
    <item>
      <title>Is DictionarySymbolPreview sample broken?</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016509#M5993</link>
      <description>&lt;P&gt;Hi -&lt;/P&gt;&lt;P&gt;Using Pro 2.7 and data from&amp;nbsp;CommunitySampleData-12-15-2020, when I choose the METOCPoints (Atmospheric), SymbolsetID:45&amp;nbsp; in the &lt;A href="https://github.com/Esri/arcgis-pro-sdk-community-samples/tree/master/Map-Authoring/DictionarySymbolPreview" target="_self"&gt;DictionarySymbolPreview sample&lt;/A&gt; I get a null reference exception.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/3764i06086A903F3E3C7F/image-size/large?v=v2&amp;amp;px=999" role="button" title="image.png" alt="image.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I wonder if something's not configured correctly.&lt;/P&gt;&lt;P&gt;Thanks, Kirk&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 19:00:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016509#M5993</guid>
      <dc:creator>KirkKuykendall1</dc:creator>
      <dc:date>2021-01-13T19:00:27Z</dc:date>
    </item>
    <item>
      <title>Re: Is DictionarySymbolPreview sample broken?</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016526#M5995</link>
      <description>&lt;P&gt;~Hi Kirk, the sample is designed for use with "mil2525d". To change it you would have to replace that literal string with the name of your dictionary. However, I think the property grid expects mil2525d entities also so that might break also but it's been quite a few years since I wrote that sample and I don't remember all the details.~&lt;/P&gt;&lt;P&gt;scratch that - I see u are using mil2525d. I'm not sure off the top of my head. Looks like the GetDictionarySymbol call does not find your selected symbol and, off the top of my head, I dont know why&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 19:18:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016526#M5995</guid>
      <dc:creator>CharlesMacleod</dc:creator>
      <dc:date>2021-01-13T19:18:09Z</dc:date>
    </item>
    <item>
      <title>Re: Is DictionarySymbolPreview sample broken?</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016558#M5999</link>
      <description>&lt;P&gt;Hi Kirk, looks like a bug in GetDictionarySymbol. I'll keep u posted.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 20:14:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016558#M5999</guid>
      <dc:creator>CharlesMacleod</dc:creator>
      <dc:date>2021-01-13T20:14:42Z</dc:date>
    </item>
    <item>
      <title>Re: Is DictionarySymbolPreview sample broken?</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016570#M6000</link>
      <description>&lt;P&gt;Starting with a fresh MilitaryOverlay.aprx from the zip file, I see a &lt;FONT color="#FF0000"&gt;!&lt;/FONT&gt;&amp;nbsp;next to the stylx:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="KirkKuykendall1_0-1610569829795.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/3791i9643A5544091B8BC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KirkKuykendall1_0-1610569829795.png" alt="KirkKuykendall1_0-1610569829795.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I clicked and browsed for:&lt;/P&gt;&lt;P&gt;"C:\Program Files\ArcGIS\Pro\Resources\Dictionaries\mil2525d\mil2525d.stylx"&lt;/P&gt;&lt;P&gt;and the ! cleared.&lt;/P&gt;&lt;P&gt;Still get null ref exception though.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 20:31:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016570#M6000</guid>
      <dc:creator>KirkKuykendall1</dc:creator>
      <dc:date>2021-01-13T20:31:39Z</dc:date>
    </item>
    <item>
      <title>Re: Is DictionarySymbolPreview sample broken?</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016598#M6001</link>
      <description>&lt;P&gt;Kirk, I dug into this a little deeper.&lt;/P&gt;&lt;P&gt;It looks like, in some cases, particular symbolsets have a "000000 - Unspecified" symbol entity as the default. The Atmospheric symbols - symbolset 45 and 46 as examples. So the initial pick of the METOCPoints, Lines, Polys triggers a search for the default entity: "symbolentity 0". Now, I _think_ the GetDictionarySymbol used to return a default symbol for undefined entities?? - but it could just be a bug in the sample - anyway, when I select a "real" entity from the symbolentity drop down (i.e. something other than 000000 - eg 110100), I get the correct symbol retrieved and loaded.&lt;/P&gt;&lt;P&gt;I think the best thing to do is simply wrap the GetDictionarySymbol call in a try/catch to prevent the null symbol being returned from blowing up the dockpane in those cases where an unspecified "000000" symbol is being requested.&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;private Task&amp;lt;ImageSource&amp;gt; GenerateBitmapImageAsync(Dictionary&amp;lt;string, object&amp;gt; attributes) {
            return QueuedTask.Run(() =&amp;gt; {
              try {
                CIMSymbol symbol = 
 ArcGIS.Desktop.Mapping.SymbolFactory.Instance.GetDictionarySymbol(
         "mil2525d", attributes);
                var si = new SymbolStyleItem() {
                  Symbol = symbol,
                  PatchHeight = 64,
                  PatchWidth = 64
                };
                return si.PreviewImage;
              }
              catch(NullReferenceException) {
                return null;
              }
            });
        }&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 21:14:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016598#M6001</guid>
      <dc:creator>CharlesMacleod</dc:creator>
      <dc:date>2021-01-13T21:14:31Z</dc:date>
    </item>
    <item>
      <title>Re: Is DictionarySymbolPreview sample broken?</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016896#M6003</link>
      <description>&lt;P&gt;This is probably a separate issue: &lt;STRONG&gt;exception when opening DictionarySymbolView designer (cannot find actipro toolwindow).&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="markdown"&gt;Severity Code Description Project File Line Suppression State
Error Type reference cannot find type named '{clr-namespace:ActiproSoftware.Windows.Controls.Docking;assembly=ArcGIS.Desktop.Docking.Wpf}ToolWindow'. DictionarySymbolPreview D:\repos\esri\arcgis-pro-sdk-community-samples\Map-Authoring\DictionarySymbolPreview\UI\DictionarySymbolView.xaml 19 
&lt;/LI-CODE&gt;&lt;P&gt;To reproduce:&lt;/P&gt;&lt;P&gt;Open sln, notice nuget packages are broken, so update to 4.0.2 ...&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="KirkKuykendall1_0-1610639476381.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/3888i49E42CFC058D976F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KirkKuykendall1_0-1610639476381.png" alt="KirkKuykendall1_0-1610639476381.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Clean and rebuild, no errors.&lt;/P&gt;&lt;P&gt;Open the DictionarySymbolView in designer and see error.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jan 2021 15:58:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/is-dictionarysymbolpreview-sample-broken/m-p/1016896#M6003</guid>
      <dc:creator>KirkKuykendall1</dc:creator>
      <dc:date>2021-01-14T15:58:35Z</dc:date>
    </item>
  </channel>
</rss>

