Thanks for looking into this Matt, it was just the confirmation I needed!

I did not have any luck re-creating the ArrayCollection: Trying out
different syntaxes I either got the same error or no error but also no
update of the TabNavigor.
It seems that due to this bug currently there is no way to get the Repeater
to work inside a TabNavigator when the underlaying Array is updated by a
class.

But there is always the possibility to clear and re-populate the Navigator
without Binding, 'manually' so to speak.
I include the code below, just in case someone else runs into this problem
and looks for a workaround.

Thanks again for your time!

--------------
Andreas Weber
motiondraw.com




<?xml version="1.0"?>
<mx:Application  xmlns:mx="http://www.macromedia.com/2005/mxml";
creationComplete="init()">
            <mx:Script>
            <![CDATA[
                import TestClass;
                private function init():Void{
                     public var myTestClass:TestClass = new TestClass();
                }
            ]]>
            </mx:Script>

    <mx:TabNavigator id="tabNav" width="100%" height="100%"/>
</mx:Application>

--------------------------
TestClass.as

package {
          import mx.containers.Canvas;
          import mx.controls.TextArea;

      public class TestClass {
            private var app = mx.core.Application.application;

            public function TestClass(){
                populateTabNavigator('char');
                        clearChildren(app.tabNav);
                        populateTabNavigator('num');
            }

            private function populateTabNavigator(mode:String):Void{
                if(mode == 'num'){
                  var data_arr:Array =[{fn:"about1", c:"1"},{fn:"about2",
c:"2"},{fn:"about3", c:"3"}];
                }else if(mode == 'char'){
                              var data_arr:Array =[{fn:"aboutOne", 
c:"One"},{fn:"aboutTwo",
c:"two"},{fn:"aboutThree", c:"Three"}];
                }
                          for(var i:int=0; i<data_arr.length; i++){
                                        var c:Canvas = new Canvas();
                                        c.label = data_arr[i].fn;
                                        var ta:TextArea = new TextArea();
                                        ta.htmlText = data_arr[i].c;
                                        ta.percentWidth = ta.percentHeight = 
100;
                                        c.addChild(ta);
                                        app.tabNav.addChild(c);
                          }
            }

            private function clearChildren(parent):Void{
                while(parent.numChildren){
                        parent.removeChildAt(0);
                }
            }
      }
}

-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED]
Behalf Of Matt Chotin
Sent: Monday, October 31, 2005 8:18 PM
To: [email protected]
Subject: RE: [flexcoders] Repeater inside TabNavigator, manipulated by class


Definitely is a bug.  I’ll go ahead and file it.  I don’t have a workaround
for you right now, maybe try re-creating the ArrayCollection instead of just
the inner array?  myAC = new ArrayCollection(projectFiles) instead of
re-assigning projectFiles.  I don’t have more time to dig on it, sorry.



Matt






------------------------ Yahoo! Groups Sponsor --------------------~--> 
Most low income households are not online. Help bridge the digital divide today!
http://us.click.yahoo.com/cd_AJB/QnQLAA/TtwFAA/nhFolB/TM
--------------------------------------------------------------------~-> 

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to