Still cannot get it work.
Here is my scenario:
1. Container adds child1 to itself.
2. Container adds child2 to itself.
Child2 adds a custom event listener to parent (Container):
parent.addEventListener("remoteDateEvent", remoteClickHandler,
false, 0, true);
3. Child1 dispatches a custom event:
private function executeRun(event:KeyboardEvent):void
{
if(event.charCode == 13)
{
var eventObj:remoteDateRun = new remoteDateRun("remoteDateEvent");
dispatchEvent(eventObj);
}
}
4. Child2 handles custom event:
public function remoteClickHandler(event:remoteDateRun):void
{
runDate = event.runDate;
dailyJobSumaryList(lineId);
}
At this point everything works.
Now, after some user action both forms are removed form the Container
and all previous steps are repeated.
At this point everything still works.
Now user is going back to his initial selection. Both forms are
removed again and 3rd set of forms is added to the Container. At this
point if a child1 dispatches a custom event then child2 form set #1
will get it to handle. Can someone please just put step by step
instruction how to make sure that a form is released and collected?
I have spent days if not more trying to fix the problem.
Thanks in advance.