just curious, why can't you use removeChildAt()? On Fri, Jun 12, 2009 at 11:58 AM, chandruflex <[email protected]> wrote:
> > > In my application, I have a Button. I want to double-click this Button, and > edit its label, just like we do in Flex Builder. > > To do this, I have a double-click event-handler for my Button. In this > event-handler, I have written code to create a TextInput control (in > ActionScript). I have specified an enter-event-handler for this TextInput > control. In the enter-event-handler of the TextInput control, I assign the > typed-in Text to my Button control. I have to remove the TextInput control > now. Here is where I have a problem. I want to remove this TextInput > control, which has been created dynamically using ActionScript, only using > "removeChild()" and not using "removeChildAt()". > > I get an error "Cannot access a property or method of a null object > reference", when using the "removeChild()" to remove the TextInput control. > > I would like to know, how I can remove this TextInput control, that I have > created using ActionScript. > > >

