<?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: Arcade label/dynamic text with thousands separator in German format in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109150#M46928</link>
    <description>&lt;P&gt;You'll have to do it manually:&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var value = 1234567890 / 1000
var x = Text(value, "#,###.0")
var pat_rep = [[".", ";"], [",", "."], [";", ","]]
for (var i in pat_rep) {
    x = Replace(x, pat_rep[i][0], pat_rep[i][1])
}
return x + " kt"

// 1.234.567,9 kt&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 20 Oct 2021 11:00:18 GMT</pubDate>
    <dc:creator>JohannesLindner</dc:creator>
    <dc:date>2021-10-20T11:00:18Z</dc:date>
    <item>
      <title>Arcade label/dynamic text with thousands separator in German format</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109146#M46927</link>
      <description>&lt;P&gt;I want to create dynamic text in a layout calculated from an attribute value and I need it to use the German way to format numbers (i.e. comma for decimal places and dot as thousands separator).&lt;/P&gt;&lt;P&gt;When I use just the field value I can check the 'Thousands separators' option and ArcGIS Pro honours the system language settings (I presume).&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Unbenannt.PNG" style="width: 271px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/25605iE3AC0552D8CF58E4/image-dimensions/271x185?v=v2" width="271" height="185" role="button" title="Unbenannt.PNG" alt="Unbenannt.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;B&lt;SPAN&gt;ut when I use an expression that option is not available. And using the text function in Arcade with number formatting creates the English format.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Here is an example:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Unbenannt.PNG" style="width: 842px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/25602i228A65665FE450C9/image-size/large?v=v2&amp;amp;px=999" role="button" title="Unbenannt.PNG" alt="Unbenannt.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Is there a way to create an Arcade text/label using German number formatting (or other non-English formats)? I'll probably need this more often, not only in layout text but also for labels or annotations.&lt;/P&gt;&lt;P&gt;I know I could create a new attribute field, but I want to avoid that, as it would produce lots of redundant data over time.&lt;/P&gt;&lt;P&gt;(I'm currently using ArcGIS Pro 2.6.1 with English UI, system language is German)&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 10:10:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109146#M46927</guid>
      <dc:creator>FranziskaSumpf</dc:creator>
      <dc:date>2021-10-20T10:10:32Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade label/dynamic text with thousands separator in German format</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109150#M46928</link>
      <description>&lt;P&gt;You'll have to do it manually:&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var value = 1234567890 / 1000
var x = Text(value, "#,###.0")
var pat_rep = [[".", ";"], [",", "."], [";", ","]]
for (var i in pat_rep) {
    x = Replace(x, pat_rep[i][0], pat_rep[i][1])
}
return x + " kt"

// 1.234.567,9 kt&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 11:00:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109150#M46928</guid>
      <dc:creator>JohannesLindner</dc:creator>
      <dc:date>2021-10-20T11:00:18Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade label/dynamic text with thousands separator in German format</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109153#M46929</link>
      <description>&lt;P&gt;Thank you, Johannes. So it's basically replacing "," with "." and vice versa using ";" as a place holder? Seems like an awful lot of calculating for such a simple thing. I hope it won't affect performance too much when used in labels. But it'll do for the layout and I like the for-loop (much more elegant than writing replace again and again like I would have &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt; ).&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 11:29:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109153#M46929</guid>
      <dc:creator>FranziskaSumpf</dc:creator>
      <dc:date>2021-10-20T11:29:07Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade label/dynamic text with thousands separator in German format</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109182#M46932</link>
      <description>&lt;P&gt;Yes, that's exactly what the code does. Performance should be OK, this is a simple operation, as opposed to e.g. intersecting another layer or filtering a table.&lt;/P&gt;&lt;P&gt;Although the loop makes the code more flexible, in this case writing the 3 Replace statements might be better (less code and fewer computations), but you wouldn't notice any performance difference.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If my answer was what you were looking for, please mark it as solution, so that your question shows up as solved.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 13:21:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-label-dynamic-text-with-thousands-separator/m-p/1109182#M46932</guid>
      <dc:creator>JohannesLindner</dc:creator>
      <dc:date>2021-10-20T13:21:05Z</dc:date>
    </item>
  </channel>
</rss>

