<esri:GraphicsLayer id="myGraphicscityName" graphicProvider="{queryTaskcityName.executeLastResult.features}" >
<esri:symbol> <esri:SimpleMarkerSymbol id="sms" size="15" color="0xFF0000" style="circle" /></esri:symbol>
<esri:infoWindowRenderer>
<fx:Component>
<esri:LabelDataRenderer >
<s:TextArea id = "textcityName" text ="The name of the city : {data.cityNamesAct}" width="100" height="75"/>
</esri:LabelDataRenderer>
</fx:Component>
</esri:infoWindowRenderer>
</esri:GraphicsLayer>
How can I display that information automatically (without user click)?
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:esri="http://www.esri.com/2008/ags"
xmlns:s="library://ns.adobe.com/flex/spark"
pageTitle="Basic InfoSymbol example">
<!--
Basic example of an infosymbol containing a vbox with an image and a label.
The image url is read from the attributes of the graphic.
http://resources.arcgis.com/en/help/flex-api/samples/01nq/01nq0000004v000000.htm
-->
<fx:Declarations>
<esri:CompositeSymbol id="compositeSymbol">
<esri:SimpleMarkerSymbol size="30" color="0xFF0000" style="circle" />
<esri:SimpleMarkerSymbol size="15" color="0x00FF00" style="triangle" angle="30" />
<esri:InfoSymbol>
<esri:infoRenderer>
<fx:Component>
<s:DataRenderer>
<s:layout>
<s:VerticalLayout/>
</s:layout>
<mx:Image source="{data.myImageURL}"/>
</s:DataRenderer>
</fx:Component>
</esri:infoRenderer>
</esri:InfoSymbol>
<esri:TextSymbol textAttribute="myTitle"
placement="end"
yoffset="-20"
border="true"
background="true"/>
</esri:CompositeSymbol>
</fx:Declarations>
<esri:Map openHandCursorVisible="false">
<esri:ArcGISTiledMapServiceLayer url="http://server.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer"/>
<esri:GraphicsLayer symbol="{compositeSymbol}">
<esri:Graphic>
<esri:geometry>
<esri:MapPoint x="11945000" y="6074000"/>
</esri:geometry>
<esri:attributes>
<fx:Object>
<fx:myImageURL>http://training.figleaf.com/images/sec_logo_flex.gif</fx:myImageURL>
<fx:myTitle>Flex</fx:myTitle>
</fx:Object>
</esri:attributes>
</esri:Graphic>
<esri:Graphic>
<esri:geometry>
<esri:MapPoint x="-7359000" y="2092000"/>
</esri:geometry>
<esri:attributes>
<fx:Object>
<fx:myImageURL>http://erevanpoker.com/bin_images/no_flash.png</fx:myImageURL>
<fx:myTitle>Flash</fx:myTitle>
</fx:Object>
</esri:attributes>
</esri:Graphic>
</esri:GraphicsLayer>
</esri:Map>
</s:Application>
<esri:GraphicsLayer id="myGraphicscityName" graphicProvider="{queryTaskcityName.executeLastResult.features}" >
<esri:symbol> <esri:SimpleMarkerSymbol id="sms" size="15" color="0xFF0000" style="circle" /></esri:symbol>
<esri:infoWindowRenderer>
<fx:Component>
<esri:LabelDataRenderer >
<s:TextArea id = "textcityName" text ="The name of the city : {data.cityNamesAct}" width="100" height="75"/>
</esri:LabelDataRenderer>
</fx:Component>
</esri:infoWindowRenderer>
</esri:GraphicsLayer>