What component are you using?
Most list based classes have a ListData property passed into
itemRenderers. You can extend ListData to contain your custom data, and
extend the List class to use your new ListData class with new data.
You could also pass in the relevant data as part of your itemRenderer's
data object.
InvertedSpear wrote:
So I need to pass additional information (an object like an associative
array) to my renderer provider which is stored nicely in a component,
but I
can't access any variables in my parent application from the
component, only
children. As a work around, I parsed the object variable to text, put
it in
an invisible <mx:Text> control, and parsed it back into an object in my
component.
I feel like a hack because I know this is horribly inefficient and
there has
to be a better way, but I couldn't come up with one.
Thoughts anyone?
~Mike
PS, I did this because I'm using a summary row in an advancedDataGrid to
divide it into sections, but I don't want to sort by the lable of each
section (which seems to be the default) but by an ID. My solution was to
pass it the ID which will sort it correctly then pull the correct
lable text
out of my object with that ID. It works perfectly like it is but does
anyone
know the "Right" way to do this?
--
View this message in context:
http://old.nabble.com/Passing-an-object-to-a-rendererProvider-tp26396466p26396466.html
<http://old.nabble.com/Passing-an-object-to-a-rendererProvider-tp26396466p26396466.html>
Sent from the FlexCoders mailing list archive at Nabble.com.
--
Jeffry Houser, Technical Entrepreneur
Adobe Community Expert: http://tinyurl.com/684b5h
http://www.twitter.com/reboog711 | Phone: 203-379-0773
--
Easy to use Interface Components for Flex Developers
http://www.flextras.com?c=104
--
http://www.theflexshow.com
http://www.jeffryhouser.com
--
Part of the DotComIt Brain Trust