[flexcoders] [Flex2] Error adding child to a ViewStack

2006-10-10 Thread Thomas Rühl
Hello flexcoders, I am trying to implement this: I have a component, that initializes with an empty viewStack instance in the stace. In my business logic, I decide during runtime, which child interfaces should be created within the viewStack - those have always the minimum type of a

RE: [flexcoders] [Flex2] Error adding child to a ViewStack

2006-10-10 Thread Dirk Eismann
Hi Thomas, this.customerViewStack.selectedChild += 1; You try to add 1 to a complex object (selectedChild is a reference to a child of the ViewStack, *not* an numeric value!). Try this: this.customerViewStack.selectedIndex += 1; this.customerViewStack.selectedIndex =

Re: [flexcoders] [Flex2] Error adding child to a ViewStack

2006-10-10 Thread Thomas Rühl
Hi Dirk, thanks, you can spare out your answer in the Flexforum then ;) Ermmm yeah, the selectedChild was a cp mistake. I tried selectedIndex and will do so again now, maybe I missed something there... Cheers, Thomas Thomas Rühl Design, Programming

Re: [flexcoders] [Flex2] Error adding child to a ViewStack

2006-10-10 Thread Thomas Rühl
..still the same - RangeError - with this: this.customerViewStack.selectedIndex = this.customerViewStack.numChildren -1; and as well with this: this.customerViewStack.selectedIndex += 1; Thomas Rühl Design, Programming Concepts akitogo OHG