The same variable every time or a different one each time? ClassFactory has a properties bag that will pass the same values every time. I suppose you can change the properties bag before each instantiation. Or you can write a custom IFactory instead.
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 sailorsea21 Sent: Tuesday, April 28, 2009 6:23 AM To: [email protected] Subject: [flexcoders] How can I pass a var to a class??? Hi everyone, is it possible to pass a variable when I call a class??? This is what I'm doing: bar.setStyle('itemRenderer', new ClassFactory(BarColorRenderer)); My class is 'BarColorRenderer' and I would like to also pass it a variable. Is it possible? This is my class: public class BarColorRenderer extends mx.skins.ProgrammaticSkin implements IDataRenderer { public function BarColorRenderer() { } } Thanks everyone.

