The reason I am trying to access another sibling is because that specific sibling cares some data that is to be used by other children. I can move it to parent's level of course but it was convinient to get right from the sibling.
--- In [email protected], "Gordon Smith" <[EMAIL PROTECTED]> wrote: > > You can call getChildAt(i) on a container to get its ith child (where > the first child is i = 0, not i = 1), regardless of whether the children > were declared at compile time or added at run time. So one way to access > the first child in the scripts of any child is as parent.getChildAt (0). > > > > It's unusual for one of an arbitrary number of children to need to > access a single sibling. Are you sure you don't want to be doing > something like dispatching an event from one child that all the children > listen for? > > > > Gordon Smith > > Adobe Flex SDK Team > > > > ________________________________ > > From: [email protected] [mailto:[EMAIL PROTECTED] On > Behalf Of markgoldin_2000 > Sent: Wednesday, June 11, 2008 6:41 PM > To: [email protected] > Subject: [flexcoders] Re: Object name from a mouse click > > > > Ok, let's say I have a container (VBox) that adds some children to > itself at the run-time. These children are: > child1, child2, child3. > How can I refer to child1 from the inside of child3? > Is there something like child3.parent.child1 avaialble? > > --- In [email protected] <mailto:flexcoders% 40yahoogroups.com> > , "Gordon Smith" <gosmith@> wrote: > > > > > I want to know objDG > > > > > > > > Sorry, that doesn't make sense. objDG isn't the name of the > DataGrid, > > it's the name of a variable that points to a DataGrid instance. You > > could lots of variables pointing to the same DataGrid instance. > > Instances don't keep track of the names of variables that point to > them. > > > > > > > > > > Can you clarify what you're really trying to do from a user's point > of > > view rather than from a programming point of view? > > > > > > > > Gordon Smith > > > > Adobe Flex SDK Team > > > > > > > > ________________________________ > > > > From: [email protected] <mailto:flexcoders% 40yahoogroups.com> > > [mailto:[email protected] <mailto:flexcoders% 40yahoogroups.com> > ] On > > Behalf Of markgoldin_2000 > > Sent: Friday, June 06, 2008 11:52 AM > > To: [email protected] <mailto:flexcoders% 40yahoogroups.com> > > Subject: [flexcoders] Re: Object name from a mouse click > > > > > > > > objDG = new myDG(); > > I want to know objDG. I have a number of GDs based on the same > class. > > Based on objDG I need to run different parts of my code. > > > > --- In [email protected] > <mailto:flexcoders%40yahoogroups.com> <mailto:flexcoders% > 40yahoogroups.com> > > , "Gordon Smith" <gosmith@> wrote: > > > > > > What do you mean by "the actual object name"? The 'id' that you > > > specified in MXML? > > > > > > > > > > > > And what object are you talking about? A component inside your > item > > > renderer? > > > > > > > > > > > > Gordon Smith > > > > > > Adobe Flex SDK Team > > > > > > > > > > > > ________________________________ > > > > > > From: [email protected] > <mailto:flexcoders%40yahoogroups.com> <mailto:flexcoders% > 40yahoogroups.com> > > > > [mailto:[email protected] > <mailto:flexcoders%40yahoogroups.com> <mailto:flexcoders% > 40yahoogroups.com> > > ] On > > > Behalf Of markgoldin_2000 > > > Sent: Friday, June 06, 2008 7:12 AM > > > To: [email protected] <mailto:flexcoders% 40yahoogroups.com> > <mailto:flexcoders% > 40yahoogroups.com> > > > Subject: [flexcoders] Object name from a mouse click > > > > > > > > > > > > I am overriding mouseDoubleClickHandler event for a custom > dataGrid. > > > How can I get the actual object name (not a class name) when I > > dblclick? > > > > > > Thanks > > > > > >

