Richro65
06-23-2007, 08:09 PM
I have a list box component and the content of the list is dynamically loaded when a user selects a category. I am trying to get my list box to jump back to the top row when the content is loaded. If they have scrolled down the list and then change the category, the list remains in the same position.
BTW, Flash 8, AS 2.
I have been reading posts all over this forum and some are saying that myListBox.selectedIndex=0 will do the trick. Some users say that it works for them, others say it does not. I have also read that the selectedIndex property cannot be changed but when I change it and then check the value of the property, it has been changed to what I set it to.
So even though the index property does accept the change, the list and scroll bar stay put.
Is there a way to force the list to display the top of the list? Being that the content of the list box is freshly loaded when I wish to scroll back to the top, is there another way around it?
Thanks for your help on this.
BTW, Flash 8, AS 2.
I have been reading posts all over this forum and some are saying that myListBox.selectedIndex=0 will do the trick. Some users say that it works for them, others say it does not. I have also read that the selectedIndex property cannot be changed but when I change it and then check the value of the property, it has been changed to what I set it to.
So even though the index property does accept the change, the list and scroll bar stay put.
Is there a way to force the list to display the top of the list? Being that the content of the list box is freshly loaded when I wish to scroll back to the top, is there another way around it?
Thanks for your help on this.