I currenty have an Hslider that is animated and affects the results presented in a bar graph but when I play through the values of the Hslider the animation is jumpy. by jumpy i mean it sometimes tries to go back a value before going forward. for example the slider value reaches 1963 then briefly goes back to 1962 then continues the odd time jumping back.
can anyone identify any errors in my approach…
public var anim:AnimateProperty = new AnimateProperty();
public function Startanimation():void {
anim.target = YEAR_SLIDER;
yearto = 2011 - YEAR_SLIDER.value;
anim.duration = yearto * 150;
anim.property = "value";
anim.fromValue = YEAR_SLIDER.value;
anim.toValue = 2011;
anim.end();
anim.play();
}
public function update_Application():void{
YEAR = YEAR_SLIDER.value;
GEONAME = COMBO.selectedLabel;
var data:Object = new Object();
data = {YEAR : YEAR, GEONAME : GEONAME};
graphdata.getdata(data);
graphdata.getdata_grid(data);
}
<mx:HSlider
id="YEAR_SLIDER" value="{YS_INITIAL_VALUE}"
minimum="{YS_INITIAL_VALUE}"
maximum="2011" change="update_Application()"
liveDragging="true" accessibilityEnabled="true"
snapInterval="1" currentState=""
tickInterval="10"
width="300" showDataTip="false"
borderColor="#133341"
alpha="1.0"
fillAlphas="[0.69, 0.64, 0.91, 0.91]" dataTipFormatFunction="datatip">
</mx:HSlider>
Thanks in advance…
Solved…//
For anyone else having this issue, it seemed to be the amount of data I was returning to the graph. Once I cleaned up my select statement to return only the specific columns needed and also created an index on the table the animation was smooth.