flexibleChild is a string, which is the id of the flexible child, so using it to reference the object won’t work. Document (which is a model of the MXML document) should be loaded at some point if it’s being used in mxml. I would put a condition to see whether it has been loaded already, and return if it hasn’t. The layout method should be called at least once after the document is loaded, so the logic would apply then.
If the document is never loaded then we have a bigger problem. From: Harbs<mailto:[email protected]> Sent: Tuesday, May 23, 2017 10:21 PM To: dev<mailto:[email protected]> Subject: [FlexJS] setDocument() I have an app which uses OneFlexibleChildVerticalLayout. I have not built the app recently, and I noticed that it’s currently failing. It seems like the error is in layout() from the following code: actualChild = document[flexibleChild]; document is never being set, and I’m not sue what the purpose of “document” is at all. Why not just use flexibleChild? Harbs
