2 Replies Latest reply on Nov 23, 2007 12:25 AM by batmitra

    Need Help on Components

    batmitra Level 1
      I have an application that needs several datagrids so i've decided to make each datagrid a component and for navigation purposes i use a Tab Navigator Control. My problem is, the first Datagrid on the tab control works great but the next ones flex give an error message saying it can not access a null object reference.

      What i've discover until now is that on each tab i have a canvas container, if i take i out , i' left without a label but my control works , with that canvas tag it doesn't work.

      Can someone help me please?
        • 1. Re: Need Help on Components
          batmitra Level 1
          it seems no one knows
          Well i managed to find exactly what the problem is, but i can't find a solution to it.

          The problem is that adding a custom component to a tabnavigator doesn't force it to initialize before the user clicks the tab where the component is , so the tabnavigator only initialize the component on the first tab.

          Now my question is, how can i force every tab to initialize the components inside them?
          • 2. Re: Need Help on Components
            batmitra Level 1
            I've found the solution to my problem , its all about creationPolicy.

            All i needed to do was to add creationPolicy="all" to my tabnavigator and it all works now.