<?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 LabelDefinition in example in .NET Maps SDK Questions</title>
    <link>https://community.esri.com/t5/net-maps-sdk-questions/labeldefinition-in-example/m-p/1155558#M10840</link>
    <description>&lt;P&gt;Is the initialisation of the LabelDefinition correct in the following example? (&lt;A href="https://developers.arcgis.com/net/styles-and-data-visualization/add-labels/" target="_blank"&gt;https://developers.arcgis.com/net/styles-and-data-visualization/add-labels/&lt;/A&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;LabelDefinition labelDefSmall = new LabelDefinition
    {
        WhereClause = "[POPULATION] &amp;lt; 500000",
        TextSymbol = textSymbolSmallCities,
        Expression = new ArcadeLabelExpression("return $feature.name;"),
        // Expression = new SimpleLabelExpression("[NAME]"),
        Placement = Esri.ArcGISRuntime.ArcGISServices.LabelingPlacement.PointBelowCenter
    };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was banging my head dealing with an error that LabelDefintion wasn't supplied the required LabelExpression parameter when, reading the documentation, I realised it should be:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;            LabelDefinition labelDefSmall = new LabelDefinition(new ArcadeLabelExpression("return $feature.name;"), textSymbolSmallCities)
            {
                WhereClause = "[POPULATION] &amp;lt; 500000",
                Placement = Esri.ArcGISRuntime.ArcGISServices.LabelingPlacement.PointBelowCenter
            };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Mon, 21 Mar 2022 00:07:29 GMT</pubDate>
    <dc:creator>TaylorCarnell1</dc:creator>
    <dc:date>2022-03-21T00:07:29Z</dc:date>
    <item>
      <title>LabelDefinition in example</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/labeldefinition-in-example/m-p/1155558#M10840</link>
      <description>&lt;P&gt;Is the initialisation of the LabelDefinition correct in the following example? (&lt;A href="https://developers.arcgis.com/net/styles-and-data-visualization/add-labels/" target="_blank"&gt;https://developers.arcgis.com/net/styles-and-data-visualization/add-labels/&lt;/A&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;LabelDefinition labelDefSmall = new LabelDefinition
    {
        WhereClause = "[POPULATION] &amp;lt; 500000",
        TextSymbol = textSymbolSmallCities,
        Expression = new ArcadeLabelExpression("return $feature.name;"),
        // Expression = new SimpleLabelExpression("[NAME]"),
        Placement = Esri.ArcGISRuntime.ArcGISServices.LabelingPlacement.PointBelowCenter
    };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was banging my head dealing with an error that LabelDefintion wasn't supplied the required LabelExpression parameter when, reading the documentation, I realised it should be:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;            LabelDefinition labelDefSmall = new LabelDefinition(new ArcadeLabelExpression("return $feature.name;"), textSymbolSmallCities)
            {
                WhereClause = "[POPULATION] &amp;lt; 500000",
                Placement = Esri.ArcGISRuntime.ArcGISServices.LabelingPlacement.PointBelowCenter
            };&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 21 Mar 2022 00:07:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/labeldefinition-in-example/m-p/1155558#M10840</guid>
      <dc:creator>TaylorCarnell1</dc:creator>
      <dc:date>2022-03-21T00:07:29Z</dc:date>
    </item>
  </channel>
</rss>

