3 Replies Latest reply on Oct 26, 2009 9:31 AM by David_F57

    How to change the currentState of child component by the button of grandchild component?

    tori0915

      Hi! Please give me your advice!!

       

      I want to control the currentState of child component by the button of grandchild component.

       

      The construction as follows;

       

      main.mxml(parent) has three states (login,menu,detail) and they are child components.

      And detail.mxml(child comp.) has header area (header.mxml(grandchild comp.)) and body area

        and state of the body area is changed(state1-3).

       

      i want to set the currentState of detail(child) to state1

        when the button on the header(grandchild comp.) is clicked

         and the state of main.mxml(parent) changes from detail to menu.

       

      by parentApplication.currentState i can change the state of main.mxml...

       

      I want to know how to change the state of detail.mxml.

       

      Thanks,