thx. .V
--- In [email protected], "Gordon Smith" <[EMAIL PROTECTED]> wrote: > > A sealed object is an instance of any class that wasn't declared with > the 'dynamic' attribute. Most classes, such as Button, are non-dynamic. > This means that if you try to access a property that wasn't declared at > compile time, you'll get a runtime error. For example, if you do > > > > var b:Button = new Button(); > > b["foo"] = 1; > > > > you'll get an RTE because the Button class didn't declare a property > named 'foo' at compile time and wasn't declared to be dynamic. > > > > But if you do > > > > var o:Object = new Object(); > > o["foo"] = 1; > > > > you'll create a new 'foo' property on o. This is allowed because the > Object class was declared to be dynamic. > > > > You declare a class to be dynamic like this: > > > > public dynamic class MyClass extends SomeOtherClass > > { > > > > } > > > > Gordon Smith > > Adobe Flex SDK Team > > > > ________________________________ > > From: [email protected] [mailto:[EMAIL PROTECTED] On > Behalf Of v.cekvenich > Sent: Wednesday, July 23, 2008 10:44 AM > To: [email protected] > Subject: [flexcoders] Re: reflection of proerties in an object > > > > Thank you both, works!!! > > What is a sealed object? > > .V > > > > > > > > > for (var p:String in object) > > > > trace(p, object[p]) > > > > > > > > For sealed objects, use getClassInfo > > > > > > > > ________________________________ > > > > From: [email protected] <mailto:flexcoders%40yahoogroups.com> > [mailto:[email protected] <mailto:flexcoders%40yahoogroups.com> > ] On > > Behalf Of v.cekvenich > > Sent: Wednesday, July 23, 2008 8:08 AM > > To: [email protected] <mailto:flexcoders%40yahoogroups.com> > > Subject: [flexcoders] reflection of proerties in an object > > > > > > > > if I get an object, I want to enumerate the properties. > > > > Ex: > > var object:Object = someClass.someFunc(); > > > > var val1:String = object["key1"]; > > > > How do I list all the keys in an object? > > > > .V > > >

