Hi,

I'm working on a project where the user can create multiple product
configurations within a single order.

Each "configuration object" holds a variety of data about chosen product
attributes, and the configuration objects are placed into an array.

In order to display all the configurations, I want to loop over the array,
and for each configuration object create an instance of a custom MXML
component, passing the new component instance the configuration object to be
displayed, and adding the new component as the child of an existing VBox.
The custom component contains a lot of Text components and a DataGrid.

I know how to create an instance of a base class, like a Button, in
ActionScript and make it a new child. But the display of a configuration is
complicated enough that it's much easier to do it as an MXML component.
Besides, I need to display a single configuration in one area of the
application and all configurations in another area.

I've done lots of Googling to no avail, and spent a good deal of time with
the Adobe docs. While I've probably missed something obvious, is there a way
to create instances of an MXML component within an ActionScript function? Or
is there a much simpler way to approach the problem?

-- 
Thanks,

Tom

Tom McNeer
MediumCool
http://www.mediumcool.com
1735 Johnson Road NE
Atlanta, GA 30306
404.589.0560

Reply via email to