Select to view content in your preferred language

Change subtitle from the ActionScript code

621
2
12-28-2010 06:01 AM
CraigPlacek
New Contributor
I want to change the subtitle of the viewer during user interaction as they switch from one custom theme to another.
Is it possible to change the subtitle value from the ActionScript code?
Tags (2)
0 Kudos
2 Replies
RobertScheitlin__GISP
MVP Emeritus
Craig,

Be sure to post FlexViewer questions to the Flex Viewer forum.

http://forums.arcgis.com/forums/111-ArcGIS-Viewer-for-Flex

This is sort of a hack but there is not an exposed way by esri to do this.

Step 1: in the WidgetManager.mxml change line 66 to public from private
public var controlContainer:Group;


Step 2: Call this code from some where
for (var c:int = 0; c < ViewerContainer.getInstance().widgetManager.controlContainer.numElements; c++){
     try{
      var hc:* = ViewerContainer.getInstance().widgetManager.controlContainer.getElementAt(c);
      hc.bannerSubtitle.text = "hello world";
     } catch(error:Error){}
    }
0 Kudos
CraigPlacek
New Contributor
Robert,

That worked great.

Thanks

-Craig
0 Kudos