<?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: Create fraction as label in Arcade in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/create-fraction-as-label-in-arcade/m-p/1283956#M68559</link>
    <description>&lt;P&gt;I was able to get a horizontal line between the two that is the length of the longer value, but I couldn't get them aligned with the decimal point.&lt;/P&gt;&lt;P&gt;When using this script, you have to unselect the "Remove extra spaces" option.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var numerator = $feature.MIN;
var denominator = $feature.MAX;

var numLength = Count(Text(numerator));
var denLength = Count(Text(denominator));
if (numLength &amp;lt; denLength) {
  var diff = Ceil((denLength - numLength)/2);
  for (var j=0; j &amp;lt;= diff; j++) {
    numerator = ` ${numerator} `
  }
}
return `&amp;lt;align horizontal ='center'&amp;gt;&amp;lt;UND&amp;gt;${numerator}&amp;lt;/UND&amp;gt;${TextFormatting.NewLine}${denominator}&amp;lt;/align&amp;gt;`&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="minmax.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/69481i0A22FA77C3C9F817/image-size/medium?v=v2&amp;amp;px=400" role="button" title="minmax.png" alt="minmax.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 28 Apr 2023 16:35:20 GMT</pubDate>
    <dc:creator>KenBuja</dc:creator>
    <dc:date>2023-04-28T16:35:20Z</dc:date>
    <item>
      <title>Create fraction as label in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/create-fraction-as-label-in-arcade/m-p/1283921#M68554</link>
      <description>&lt;P&gt;I would like to use Arcade to show z-min and z_max (both are attributes of the features) in a fraction.&lt;/P&gt;&lt;P&gt;To get both values as a multi-line label is easy, but then I am basically missing two things.&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;draw a horizontal line between the two values (ideally as wide as the longest value)&lt;/LI&gt;&lt;LI&gt;both attribute values are of type Double, and I would like to align the numbers by the decimal seperator&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Is that possible with Arcade, and/or is there any other way to achieve that with ArcGIS Pro?&lt;/P&gt;</description>
      <pubDate>Fri, 28 Apr 2023 15:21:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/create-fraction-as-label-in-arcade/m-p/1283921#M68554</guid>
      <dc:creator>TomGeo</dc:creator>
      <dc:date>2023-04-28T15:21:00Z</dc:date>
    </item>
    <item>
      <title>Re: Create fraction as label in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/create-fraction-as-label-in-arcade/m-p/1283956#M68559</link>
      <description>&lt;P&gt;I was able to get a horizontal line between the two that is the length of the longer value, but I couldn't get them aligned with the decimal point.&lt;/P&gt;&lt;P&gt;When using this script, you have to unselect the "Remove extra spaces" option.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var numerator = $feature.MIN;
var denominator = $feature.MAX;

var numLength = Count(Text(numerator));
var denLength = Count(Text(denominator));
if (numLength &amp;lt; denLength) {
  var diff = Ceil((denLength - numLength)/2);
  for (var j=0; j &amp;lt;= diff; j++) {
    numerator = ` ${numerator} `
  }
}
return `&amp;lt;align horizontal ='center'&amp;gt;&amp;lt;UND&amp;gt;${numerator}&amp;lt;/UND&amp;gt;${TextFormatting.NewLine}${denominator}&amp;lt;/align&amp;gt;`&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="minmax.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/69481i0A22FA77C3C9F817/image-size/medium?v=v2&amp;amp;px=400" role="button" title="minmax.png" alt="minmax.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Apr 2023 16:35:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/create-fraction-as-label-in-arcade/m-p/1283956#M68559</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2023-04-28T16:35:20Z</dc:date>
    </item>
    <item>
      <title>Re: Create fraction as label in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/create-fraction-as-label-in-arcade/m-p/1284240#M68587</link>
      <description>&lt;P&gt;Thank you so much! I can see the issue with the alignment to the decimal point... Lucky enough it's not a strict requirement, but in terms of typography and cartography it would be nice if Arcade could support that.&lt;/P&gt;</description>
      <pubDate>Mon, 01 May 2023 06:57:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/create-fraction-as-label-in-arcade/m-p/1284240#M68587</guid>
      <dc:creator>TomGeo</dc:creator>
      <dc:date>2023-05-01T06:57:01Z</dc:date>
    </item>
  </channel>
</rss>

