Popups added  in ArcGIS online map not honored in Flex Application

3301
1
04-22-2014 08:14 AM
by Anonymous User
Not applicable
Original User: ionara_wilson

I created an image service and added this image service to a map in ArcGIS online. Then I used this map created in AGOL in a Flex application. I added popups in AGOL, but when I run the Flex application pointing to the map in AGOL, the popups are not there when I click on the image. Shouldn't Flex honor the popups created in AGOL? If I create an application in AGOL using that map, I can see the popups, but why not in Flex? Thanks

Here is the Flex code:
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
      xmlns:s="library://ns.adobe.com/flex/spark"
      xmlns:esri="http://www.esri.com/2008/ags"
      initialize="application_initializeHandler(event)">
 
 <fx:Script>
  <![CDATA[
   
   import com.esri.ags.events.WebMapEvent;
   import mx.controls.Alert;
   import mx.events.FlexEvent;
   import com.esri.ags.Map;
   import mx.collections.ArrayCollection;
  
   
   protected function application_initializeHandler(event:FlexEvent):void
   {
    webMapUtil.createMapById("c39b222a78b84c11a8ef3fd532d6c4fb");
  
    
   }
   
   protected function webMapUtil_createMapByIdCompleteHandler(event:WebMapEvent):void
   {
 
    var map:Map = event.map;
    mapContainer.addElement(map);
  
  
   }
  ]]>
 </fx:Script>
 
 <fx:Declarations>
  <esri:WebMapUtil id="webMapUtil"
       ignorePopUps="false"
       
       createMapByIdComplete="webMapUtil_createMapByIdCompleteHandler(event)"
       fault="Alert.show(event.fault.faultString);"/>
 </fx:Declarations>
 
 <s:Label top="10"
    fontSize="24"
    horizontalCenter="0"
    text="ArcGIS.com Web Map"/>
 <s:HGroup width="100%" height="100%"
     gap="0">
  <s:Group id="mapContainer"
     width="100%" height="100%"/>

 </s:HGroup>
</s:Application>



[ATTACH=CONFIG]33249[/ATTACH]

[ATTACH=CONFIG]33250[/ATTACH]
0 Kudos
1 Reply
BjornSvensson
Esri Regular Contributor
I created an image service and added this image service to a map in ArcGIS online. ... Shouldn't Flex honor the popups created in AGOL?


Yes, in general, popups created in AGOL and part of web maps should work in Flex applications.

If I create an application in AGOL using that map, I can see the popups, but why not in Flex?


However, ArcGIS API for Flex does not support popups on imageservices.  Which is why it's not working in your specific case.
0 Kudos