parentDocument should be ready to go in your data setter. Test it like this.
override public function set data(value:Object):void
{
trace(parentDocument);
}
Alex Harui
Flex SDK Developer
Adobe Systems Inc.<http://www.adobe.com/>
Blog: http://blogs.adobe.com/aharui
From: [email protected] [mailto:[email protected]] On Behalf
Of oneworld95
Sent: Tuesday, February 24, 2009 9:05 AM
To: [email protected]
Subject: [flexcoders] Re: parentDocument variables
By the way, if there's a better way to do it, please let me know.
Thanks :)
- Alex C
--- In [email protected]<mailto:flexcoders%40yahoogroups.com>,
"oneworld95" <oneworl...@...> wrote:
>
> Awhile back, someone on this group mentioned that a good way for a
> component inside an itemRenderer to access variables in the
> parentDocument was to use custom events. I've found some info on
> custom events, but can't quite wrap my brains around how this would
> work with the itemRenderer's set data() function, where the
> parentDocument variable needs to be accessed. Your help is much
> appreciated.
>
> - Alex C
>