Perfect thanks! Forgot all about outerDocument :-)
--- In [email protected], Alex Harui <aha...@...> wrote:
>
> Try outerDocument
>
>
> On 5/25/10 10:16 PM, "jmfillman" <jmfill...@...> wrote:
>
>
>
>
>
>
> I have an itemRenderer:
>
> <mx:DataGridColumn headerText="" dataField="remove" width="20">
> <mx:itemRenderer>
> <fx:Component>
> <mx:Image source="assets/Remove-32.png" height="20" width="20"
> useHandCursor="true" buttonMode="true" click="trace (parentDocument);
> parentDocument.removeItem()"/>
> </fx:Component>
> </mx:itemRenderer>
>
> When I first load the state where the DataGrid is, add items to the grid,
> remove items from the grid, etc., the trace returns the root application
> (My_Site). When I subsequently change states and then back to the state where
> the DataGrid is located, the trace returns the container:
>
> My_Site.ApplicationSkin2._ApplicationSkin_Group1.contentGroup._My_Site_SkinnableContainer1.mainContainer6
>
> This causes an error, so the question is, how do I call the function
> regardless.
>
>
>
>
>
>
> --
> Alex Harui
> Flex SDK Team
> Adobe System, Inc.
> http://blogs.adobe.com/aharui
>