0

I must turn a Flex code into an Apache Royale one but in my research, there is on attribute for which i dont find the equivalent.

In Flex, to call an actionScipt function from a parent mxml, I have:

<mx:Button label="Login" click="parentDocument.myfunction()"/>

I found parentComponent during my research, but i have Access of possibly undefined property parentComponent error.

I also tried just 'parent' and the error became Call to a possibly undefined method verif_sharedobject through a reference with static type IParent.

I did some research about IParent, Container and Group (From jewel) but for the moment I have no success

Tellimi
  • 89
  • 10

1 Answers1

0

please check ParentDocumentBead bead from Core library.

From asdoc :

     *  The ParentDocumentBead class looks up the parent
     *  chain to find a parent that was written in MXML.
     *  Because it is usually rare for an application
     *  to need to know this information, an optional bead
     *  is used to compute it, instead of baking in the
     *  overhead of a recursive infrastucture to store
     *  this information.  It is intended to be used
     *  as a bead in the top-level tag of an MXML document.

HTH

Carlos Rovira
  • 507
  • 2
  • 11