Yes you could create the class and build it into an RSL. Once the RSL is loaded 
you can just reference it by name. When you add or make changes you just need 
to rebuild the RSL or push a new RSL out and have a way for your app to know 
whats available.

I found it easier to use Modules, because they are easier to build. I have 
examples of both RSL and Modules on that blog both have source enabled so you 
can take a look.

I have an app that lets users pick and choose "widgets" they want and I load 
only the components they want into the app via a config file. When ever I want 
to add new components I just publish a new module and update my database so my 
apps knows about it.

--- In [email protected], "postwick" <p...@...> wrote:
>
> From your blog post...
> 
> var myClass:Class = getDefinitionByName("com.myDomain.myPackage.SomeClass");
> 
> 
> Does this mean I don't have to create the class as a .as file and compile it 
> into the SWF, I can just reference it this way?  Then I could add a new class 
> to myPackage and tell my app (via db, XML, etc) that there is a new class 
> there to load?
> 
> The point to all of this is a dynamic application where an end user can add 
> their own tables, and I need classes for those objects so that I can pass 
> them back and forth with data messaging. 
> 
> 
> --- In [email protected], Alan Shaw <nodename@> wrote:
> >
> > There are a number of important techniques for manipulating classes (as 
> > detailed
> > in my post http://nodename.com/blog/2008/06/15/upon-reflection/ ), but
> > unfortunately
> > creating a class at runtime is not possible in AS3.
> > 
> > On Mon, Jul 13, 2009 at 8:23 PM, postwick<paul@> wrote:
> > >
> > >
> > > I want to store descriptions of classes in an external file (such as XML) 
> > > or
> > > database, and use them in my Flex application such that I can add, remove,
> > > or change the classes in the external file with recompling the Flex
> > > application.
> > >
> > > Is there any way to do this? In a nutshell, is there a way to create a 
> > > class
> > > through an Actionscript function, with a for loop where the information 
> > > that
> > > is looped over contains the definitions of the classes loaded from an
> > > external source?
> > >
> > >
> >
>


Reply via email to