<?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: return layer symbol url in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1143844#M76343</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Thanks for the advise but it didn't work.&amp;nbsp; It also made it so the LayerList no longer can toggle the visibility&amp;nbsp;&lt;SPAN&gt;of it.&amp;nbsp; Any suggestions?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;const VBA = new FeatureLayer({
   url: "https://cdw.maps.va.gov/server/rest/services/Map/FeatureServer/6",
   visible: true
   });

map.add(VBA);

const VBAsymbol = VBA.renderer.symbol.clone();
symbolUtils.renderPreviewHTML(VBAsymbol, {
   node: document.getElementById("VBA_Img"),
   size: 8
   });&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;span id="VBA_Text"&amp;gt;VBA Regional Offices&amp;lt;/span&amp;gt;&amp;lt;img id="VBA_Img" /&amp;gt;&amp;lt;br /&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 14 Feb 2022 21:28:18 GMT</pubDate>
    <dc:creator>KevinDunlop</dc:creator>
    <dc:date>2022-02-14T21:28:18Z</dc:date>
    <item>
      <title>return layer symbol url</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1142248#M76304</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am looking for a method that gets the FeatureLayer symbol URL either from the Feature Service itself or the FeatureLayer.&amp;nbsp; My goal is to use that url to change the src&amp;nbsp; on a &amp;lt;img&amp;gt; value that I use in a different part of my web application.&amp;nbsp; I haven't been able to find a Javascript 4.x method that returns this.&lt;/P&gt;&lt;P&gt;Can anyone point me in the right direction&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;const VBA = new FeatureLayer({
url: "https://gis.va.gov/server/rest/services/PROJECTS/VBA_VHA_NCA_Regional_and_Major_Facilities/FeatureServer/0",
title: "VBA"
});

document.getElementById("VBA_Img").src=VBA.renderer.symbol.url;&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;span id="VBA_Text"&amp;gt;VBA&amp;lt;/span&amp;gt;&amp;lt;img id="VBA_Img" /&amp;gt;&amp;lt;br /&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 09 Feb 2022 18:02:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1142248#M76304</guid>
      <dc:creator>KevinDunlop</dc:creator>
      <dc:date>2022-02-09T18:02:55Z</dc:date>
    </item>
    <item>
      <title>Re: return layer symbol url</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1142274#M76306</link>
      <description>&lt;P&gt;You can use symbolUtils.renderPreviewHTML for something like this.&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-symbols-support-symbolUtils.html#renderPreviewHTML" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/api-reference/esri-symbols-support-symbolUtils.html#renderPreviewHTML&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 09 Feb 2022 18:58:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1142274#M76306</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2022-02-09T18:58:30Z</dc:date>
    </item>
    <item>
      <title>Re: return layer symbol url</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1143844#M76343</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Thanks for the advise but it didn't work.&amp;nbsp; It also made it so the LayerList no longer can toggle the visibility&amp;nbsp;&lt;SPAN&gt;of it.&amp;nbsp; Any suggestions?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;const VBA = new FeatureLayer({
   url: "https://cdw.maps.va.gov/server/rest/services/Map/FeatureServer/6",
   visible: true
   });

map.add(VBA);

const VBAsymbol = VBA.renderer.symbol.clone();
symbolUtils.renderPreviewHTML(VBAsymbol, {
   node: document.getElementById("VBA_Img"),
   size: 8
   });&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;span id="VBA_Text"&amp;gt;VBA Regional Offices&amp;lt;/span&amp;gt;&amp;lt;img id="VBA_Img" /&amp;gt;&amp;lt;br /&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Feb 2022 21:28:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1143844#M76343</guid>
      <dc:creator>KevinDunlop</dc:creator>
      <dc:date>2022-02-14T21:28:18Z</dc:date>
    </item>
    <item>
      <title>Re: return layer symbol url</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1143855#M76344</link>
      <description>&lt;P&gt;You may have to wait for the view or layer to be finished. Also make sure it's an image, and not svg, depending on how it was created. This sample works grabs the layer and iterates the uniqueValueInfos&lt;/P&gt;&lt;P&gt;&lt;A href="https://codepen.io/odoe/pen/rNYGjVg?editors=1000" target="_blank"&gt;https://codepen.io/odoe/pen/rNYGjVg?editors=1000&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Feb 2022 22:04:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/return-layer-symbol-url/m-p/1143855#M76344</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2022-02-14T22:04:53Z</dc:date>
    </item>
  </channel>
</rss>

