<?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: Dynamic Legends: Missing Images after Idle/Long Application Duration in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326172#M7796</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Shawn,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; The setup needs to be run on the server. The line number might not be 402 but it will be in the LiveMapsWidget.mxml.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 21 Jun 2010 22:05:09 GMT</pubDate>
    <dc:creator>RobertScheitlin__GISP</dc:creator>
    <dc:date>2010-06-21T22:05:09Z</dc:date>
    <item>
      <title>Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326165#M7789</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I have dynamic legends working fine for the most part, as per Robert's code from:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://forums.esri.com/thread.asp?c=158&amp;amp;f=2421&amp;amp;t=299116&amp;amp;mc=137"&gt;http://forums.esri.com/thread.asp?c=158&amp;amp;f=2421&amp;amp;t=299116&amp;amp;mc=137&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;However, I notice that if the user's session in the SFV application goes, say, over 20-30 minutes the images for the legends are not being returned by the server.&lt;/SPAN&gt;&lt;STRONG&gt; Please see the attached screen cap&lt;/STRONG&gt;&lt;SPAN&gt;. Using Service Capture I can see 404 errors pointing toward various .png files. I think these .png files are dynamically created by the ArcGIS Server's Map Service and their names change upon refreshing the browser (upon which the legends start working again -most- of the time).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I suspect there is some kind of 'flush' of data or some kind of 'recycling' of Services going on. May be something like:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://forums.arcgis.com/threads/3177-Services-Fail-To-Load-in-SFV-Unless-Recently-Recycled-in-ArcGIS-Server"&gt;http://forums.arcgis.com/threads/3177-Services-Fail-To-Load-in-SFV-Unless-Recently-Recycled-in-ArcGIS-Server&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;Obviously, we can't have user's session limited to less than half hour or so and we can't expect them to refresh their browser window to get rid of the problem. I kind of remember our ArcGIS Server admin--who is also quite new to the management aspect of the server--telling me that he has some kind of 'flush' going on periodically. I will check with him but I want to get your input on this first.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Meengla&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 May 2010 14:31:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326165#M7789</guid>
      <dc:creator>IrfanClemson</dc:creator>
      <dc:date>2010-05-04T14:31:13Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326166#M7790</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Meengla,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; This was always an issue, but I fixed it a while ago so here is the new code for the LegendData.mxml file. it uses a loader that loads the bytes from the image url instead of just having the image reference the url that might have been deleted on the server.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;
&amp;lt;!--
////////////////////////////////////////////////////////////////////////////////
//
// Copyright © 2008 ESRI
//
// All rights reserved under the copyright laws of the United States.
// You may freely redistribute and use this software, with or
// without modification, provided you include the original copyright
// and use restrictions.&amp;nbsp; See use restrictions in the file:
// &amp;lt;install location&amp;gt;/FlexViewer/License.txt
//
////////////////////////////////////////////////////////////////////////////////
--&amp;gt;
&amp;lt;mx:HBox xmlns:mx&amp;nbsp; ="http://www.adobe.com/2006/mxml" 
&amp;nbsp;&amp;nbsp; xmlns:flash&amp;nbsp; ="flash.filters.*" 
&amp;nbsp;&amp;nbsp; width&amp;nbsp;&amp;nbsp; ="95%" 
&amp;nbsp;&amp;nbsp; minHeight&amp;nbsp; ="22" 
&amp;nbsp;&amp;nbsp; backgroundAlpha ="1" 
&amp;nbsp;&amp;nbsp; paddingLeft&amp;nbsp; ="3" 
&amp;nbsp;&amp;nbsp; paddingRight ="3" 
&amp;nbsp;&amp;nbsp; verticalAlign ="middle" backgroundColor="#FFFFFF"&amp;gt;
 
 &amp;lt;mx:Script&amp;gt;
&amp;nbsp; &amp;lt;![CDATA[
&amp;nbsp; 
&amp;nbsp;&amp;nbsp; import flash.display.Loader;
&amp;nbsp; 
&amp;nbsp;&amp;nbsp; [Bindable]
&amp;nbsp;&amp;nbsp; private var recicon:String = "";
&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; [Bindable]
&amp;nbsp;&amp;nbsp; private var title:String;
&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; private var _infoData:Object;
&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; private var _loader:Loader; 
&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; public function get infoData():Object
&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp; return _infoData;
&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; public function set infoData(value:Object):void
&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp; _infoData = value;
&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; _loader&amp;nbsp; = new Loader();
&amp;nbsp;&amp;nbsp;&amp;nbsp; _loader.contentLoaderInfo.addEventListener(Event.COMPLETE,function(e:Event):void
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; { 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; recIcon.source = e.currentTarget.content;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; recIcon.visible = true;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; recIcon.includeInLayout = true;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; );
&amp;nbsp;&amp;nbsp;&amp;nbsp; _loader.load(new URLRequest(encodeURI(infoData.icon))); 
&amp;nbsp;&amp;nbsp;&amp;nbsp; title = infoData.title;
&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp; 
&amp;nbsp; ]]&amp;gt;
 &amp;lt;/mx:Script&amp;gt;
 
 &amp;lt;mx:Image id="recIcon" visible="false" includeInLayout="false" /&amp;gt;
 &amp;lt;mx:VBox verticalGap="0" width="90%"&amp;gt;
&amp;nbsp; &amp;lt;mx:Text selectable="false" fontWeight="bold" text="{title}" width="90%"/&amp;gt;
 &amp;lt;/mx:VBox&amp;gt;
&amp;lt;/mx:HBox&amp;gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 15:27:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326166#M7790</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2021-12-11T15:27:18Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326167#M7791</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Robert,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That did the trick! Thanks!&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Meengla&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 May 2010 17:19:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326167#M7791</guid>
      <dc:creator>IrfanClemson</dc:creator>
      <dc:date>2010-05-04T17:19:05Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326168#M7792</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Meengla,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; I have begun to work on a new one for ArcGIS Server 10 and the New Flex web API Viewer that will be so much simpler to get working (no web service), and will be an independent widget (not part of the TOC widget). It will still be completely dynamic (updating when layers are turned on and off and scale ranges will be honored). Plans are to make the config xml file that has a list of map services and layers of those map services that you want excluded from the legend. Legend swatches will draw using Flex 4 Graphic Primitives and not require images from the server (in most cases), so it will also require Flex 4 and at least Flash Player 10, which will be required by the New Flex web API Viewer anyway.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 May 2010 20:43:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326168#M7792</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2010-05-04T20:43:00Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326169#M7793</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Robert,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I have advised my institution to start migrating toward ArcGIS Server 10 and Flex API 2 and Flex 4. That process is going to take time. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;But, meanwhile, I notice that even using the modified legenddata.mxml per your code above is not working for me: I still see 404 errors related to .png graphics of the legends icons.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is what my Service Capture tells me:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;At 9:00 AM, &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;GET /arcgisoutput/_ags_leg22f08466ff714f55889e54d097763b30.png &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;server returned HTTP/1.1 200 OK&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;At 9:30 AM,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;GET /arcgisoutput/_ags_leg22f08466ff714f55889e54d097763b30.png HTTP/1.1&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;server returned HTTP/1.1 404 Not Found and my Flex debugger pops up:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Error #2044: Unhandled IOErrorEvent:. text=Error #2036: Load Never Completed.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't think loading the bytes is going to help when there is no image existing on the server to load?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have spent too much time on this to let it fail; I have managed to program the dynamic legends in the SearchWidget.mxml file as well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any idea about what is happening? As I said above, there is some kind of 'recycling' of data going on ArcGIS Server; please note that the dynamic legends SOAP calls always return the layer names--just the images/icons of legends are being lost after extended user sessions.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you don't mind I can send you a link to the deployed web app; I don't have the authority to share that link openly yet.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Meengla&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 May 2010 12:42:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326169#M7793</guid>
      <dc:creator>IrfanClemson</dc:creator>
      <dc:date>2010-05-07T12:42:47Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326170#M7794</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Meengla,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Well I thought that I had that issue resolved using the loader... I guess it's back to the drawing board on this one. For now you can fix the issue by setting the directory cleanup to 1 hour on your ArcGISOutput folder in ArcGIS Server Manager. So go to server manager and click GIS Server button on the left and then Server Directories, once there verify that the chow combobox says Output Directories and then click the Edit (little pencil icon), look at the Maximum File Age: and set to 60 minute(s)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 May 2010 13:16:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326170#M7794</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2010-05-07T13:16:55Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326171#M7795</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Robert I downloaded and installed the 39609.zip file you had in another post.&amp;nbsp; It was for allowing for a dynamic legend.&amp;nbsp; I have a couple questions.&amp;nbsp; In the readme.txt in the zip file it says to "on line 402 change &lt;/SPAN&gt;&lt;A href="http://yourserver/restLegend/restLegend.asmx?wsdl"&gt;http://yourserver/restLegend/restLegend.asmx?wsdl&lt;/A&gt;&lt;SPAN&gt; to your server".&amp;nbsp; What file is line 402 in?&amp;nbsp; Also, I create my projects on my local machine and then move them to my production server to deploy.&amp;nbsp; Do I run the setup.exe contained in the zip file on my local machine or the server?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Jun 2010 21:40:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326171#M7795</guid>
      <dc:creator>ShawnKraft</dc:creator>
      <dc:date>2010-06-21T21:40:10Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326172#M7796</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Shawn,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; The setup needs to be run on the server. The line number might not be 402 but it will be in the LiveMapsWidget.mxml.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Jun 2010 22:05:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326172#M7796</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2010-06-21T22:05:09Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326173#M7797</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Meengla,&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; Well I thought that I had that issue resolved using the loader... I guess it's back to the drawing board on this one. For now you can fix the issue by setting the directory cleanup to 1 hour on your ArcGISOutput folder in ArcGIS Server Manager. So go to server manager and click GIS Server button on the left and then Server Directories, once there verify that the chow combobox says Output Directories and then click the Edit (little pencil icon), look at the Maximum File Age: and set to 60 minute(s)&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Robert,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Sorry for being late; it did take some time having access to the Server...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Increasing to 60 minutes has definitely improved the situation. Still, if&amp;nbsp; a user's session exceeds 60 minutes then the problem happens. But I am okay for now.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jun 2010 17:21:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326173#M7797</guid>
      <dc:creator>IrfanClemson</dc:creator>
      <dc:date>2010-06-22T17:21:31Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326174#M7798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi, Robert,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I wonder if you are still following this thread, but I have the same problem about missing swatches.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is my situation:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I am using 39609MapLegendWidget.zip from this link &lt;/SPAN&gt;&lt;A href="http://forums.esri.com/thread.asp?c=158&amp;amp;f=2421&amp;amp;t=299116&amp;amp;mc=137"&gt;http://forums.esri.com/thread.asp?c=158&amp;amp;f=2421&amp;amp;t=299116&amp;amp;mc=137&lt;/A&gt;&lt;SPAN&gt;, it has been working perfectly on my local server (I run arcgis server 9.3.1 and flex viewer 1.3 on the same pc). However, when I migrate the arcgis server to another server, and I access this server through IP address (don't know if it has fully qualified name), the missing swatches problems came up. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I test the &lt;/SPAN&gt;&lt;A href="http://localhost/restLegend/restLegend.asmx"&gt;http://localhost/restLegend/restLegend.asmx&lt;/A&gt;&lt;SPAN&gt; on the server, and the returned url for the swatches is something like &lt;/SPAN&gt;&lt;A href="http://wllbgis(server" s="s"&gt;http://wllbgis(server's&lt;/A&gt;&lt;SPAN&gt; name)/arcgisoutput/_ags_leg89d320faf9224f2fb2b37589f246d1d0.png. I tested this on my local pc with &lt;/SPAN&gt;&lt;A href="http://205.189.23.11(IP"&gt;http://205.189.23.11(IP&lt;/A&gt;&lt;SPAN&gt; of the server)/arcgisoutput/_ags_leg012f6eca60594fa7b354e08b233baec6.png, and it is accessible through ie. But the swatches are missing from flex viewer. If I run the flex viewer on the server end, the swatches can be displayed perfectly. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am just guessing that if the result of &lt;/SPAN&gt;&lt;A href="http://localhost/restLegend/restLegend.asmx"&gt;http://localhost/restLegend/restLegend.asmx&lt;/A&gt;&lt;SPAN&gt; would return the url with ip not the server's name, it would be able to load the legend through the interest. So any suggestions? Thanks for your help in advance.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Ruibo&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 06:20:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326174#M7798</guid>
      <dc:creator>RuiboHan</dc:creator>
      <dc:date>2010-12-03T06:20:49Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326175#M7799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Rubio,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Your fully qualified domain name is &lt;/SPAN&gt;&lt;A href="http://wlu-23-11.wlu.ca"&gt;http://wlu-23-11.wlu.ca&lt;/A&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;You really want to get away from using local host or the IP address.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So ensure you are using &lt;/SPAN&gt;&lt;A href="http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx?WSDL"&gt;http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx?WSDL&lt;/A&gt;&lt;SPAN&gt; in your LivemapsWidget.mxml&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 12:25:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326175#M7799</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2010-12-03T12:25:12Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326176#M7800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Rubio,&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Your fully qualified domain name is &lt;A href="http://wlu-23-11.wlu.ca"&gt;http://wlu-23-11.wlu.ca&lt;/A&gt; &lt;BR /&gt;You really want to get away from using local host or the IP address.&lt;BR /&gt;&lt;BR /&gt;So ensure you are using &lt;A href="http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx?WSDL"&gt;http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx?WSDL&lt;/A&gt; in your LivemapsWidget.mxml&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks a lot, Robert, a stupid question: how to get my qualified domain name? &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I changed it to &lt;/SPAN&gt;&lt;A href="http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx?WSDL"&gt;http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx?WSDL&lt;/A&gt;&lt;SPAN&gt;, but the problem persists. Any ideas?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 13:12:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326176#M7800</guid>
      <dc:creator>RuiboHan</dc:creator>
      <dc:date>2010-12-03T13:12:38Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326177#M7801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Rubio,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Just google "ip reverse lookup".&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So when you put &lt;/SPAN&gt;&lt;A href="http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx"&gt;http://wlu-23-11.wlu.ca/restLegend/restLegend.asmx&lt;/A&gt;&lt;SPAN&gt; in your web browser from the server and enter valid parameters what do the swatch urls look like?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 13:16:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326177#M7801</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2010-12-03T13:16:20Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326178#M7802</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;it is still &lt;/SPAN&gt;&lt;A href="http://wllbgis/arcgisoutput/_ags_legf664d458df954e10a952fbcbdf3b7991.png"&gt;http://wllbgis/arcgisoutput/_ags_legf664d458df954e10a952fbcbdf3b7991.png&lt;/A&gt;&lt;SPAN&gt;, anything I need to do on the server end?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 13:22:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326178#M7802</guid>
      <dc:creator>RuiboHan</dc:creator>
      <dc:date>2010-12-03T13:22:35Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326179#M7803</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Ruibo,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Yep this is a common problem that has to be addressed in the WebService code. So that means you have to rebuild the webservice on your end using visual studio. The restLegend.vb file has a portion in it's code that needs to changed and uncommented.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;''generates object for the specified MapServerLegendClass
&amp;nbsp;&amp;nbsp;&amp;nbsp; Private Function legendClass(ByVal lclass As MapServerLegendClass) As jcLegend
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim jcLeg As New jcLegend
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; jcLeg.label = lclass.Label
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ''!--you may need the line below if you webserver return a image url that is not a 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ''fully(qualified) url address--!
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; jcLeg.url = Replace(lclass.SymbolImage.ImageURL, "wllbgis", "wlu-23-11.wlu.ca")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ''jcLeg.url = lclass.SymbolImage.ImageURL
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Return jcLeg
&amp;nbsp;&amp;nbsp;&amp;nbsp; End Function
&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 15:27:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326179#M7803</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2021-12-11T15:27:20Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic Legends: Missing Images after Idle/Long Application Duration</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326180#M7804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Robert, you rock as always!!!!! Got everything work now!!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Actually, I saw that note you put in restLegend.vb, and also uncomment that with the server's ip, but didn't commnet out the following line...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Now it is running perpectly, even with the ip address, again, Robert, thank you so much, you can't imagine how much I appreciate your help.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 13:46:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/dynamic-legends-missing-images-after-idle-long/m-p/326180#M7804</guid>
      <dc:creator>RuiboHan</dc:creator>
      <dc:date>2010-12-03T13:46:27Z</dc:date>
    </item>
  </channel>
</rss>

