--- In flexcoders@yahoogroups.com, "lehaianh1986" <lehaianh1...@...> wrote: > > How? I don't understand what you say. If I click on header of > AdvancedDataGrid or another area, it false because an object have no data > property. But when I click on row item in AdvancedDataGrid, an object I > collect have data property. I use code > if (inObj.hasOwnProperty("data")) > to avoid wrong case, after that I assign inObj.data to obj > > I don't know why I still see value of data, but I can't assign it > > Any one help me?
Here, you've chosen to type your variable as InteractiveObject: vvvvvvvvvvvvvvvv var inObj:InteractiveObject; inObj = evt.mouseTarget; Yet you say that the actual data type of your object is this: inObj = inObj = (mx.controls.advancedDataGridClasses.AdvancedDataGridItemRenderer) mx.controls.advancedDataGridClasses.AdvancedDataGridItemRenderer (@9385479) AdvancedDataGridItemRenderer has a data property. InteractiveObject, its great-great-grandparent class, does not. So, you have the choice of typing this object as anything in its inheritance chain, plus the five interfaces it implements. You've chosen to type it as InteractiveObject, which doesn't have a data property, nor does UITextField, FlexTextField, DisplayObject, EventDispatcher, or Object. Change var inObj:InteractiveObject to var inObj:SomeClassOrInterfaceThatHasADataProperty HTH; Amy