2 Replies Latest reply on May 13, 2008 12:47 AM by sulletf

    dynamic layout change in Application object

      I the following moving from a vertical or horizontal layout of the Application will not have effect.
      Is there any specific method to run for it to work ?


      <?xml version="1.0" encoding="utf-8"?>

      <mx:Application xmlns:mx=" http://www.adobe.com/2006/mxml" >


      private function init():void {
      this.layout= String(layoutType.selectedValue);


      <mx:HBox x="0" y="0">
      <mx:RadioButtonGroup id="layoutType" itemClick="init();"/>
      <mx:RadioButton id="vertical" label="vertical" groupName="layoutType" value="vertical" />
      <mx:RadioButton id="horizontal" label="horizontal" groupName="layoutType" value="horizontal" />
      <mx:RadioButton id="absolute" label="absolute" groupName="layoutType" value="absolute" />

      <mx:Button label="1" x="50" y="50"/>
      <mx:Button label="2" x="150" y="150"/>
      <mx:Button label="3" x="250" y="250"/>