I need help with flash programming as I am very new to the action script language.
I have a ScrollPane and I want to get and set the scroll bars position (pixel position).
For example, if the user changes the scroll bars position and then refreshes the page, we need to take the user at the same point where he was before refresh.
For this I need to get the respective scroll bars positions before refresh and then set it to the saved position after load.
I have got the positions by hPostion and vPosition but now when I try to save the values back to the same properties after refresh it doent work.
Please let me know if this is possible in ActionScript2.
First I want to tell u that this properties force scrollpane the change its position. they are not read only.
Normally components took some time to load. And if you try to assign any property before their loading finish. it wont work.
So you need to wait untill your component loads fully.
You can check that vposition and hposition is not settting componet by assiging these value after some seconds like :
var intervalID:Number=setInterval(3000, setPan)
How/where are you saving these properties? If you are setting them in the Flash file they are being reset when the Flash file reloads.