Thursday, April 22, 2010

how you can add tick marks to a Flash/ActionScript 3.0 Slider control

The following example shows how you can add tick marks to a Flash/ActionScript 3.0 Slider control by setting the tickInterval property.

Full code after the jump.

// ActionScript 3.0
/**
* Requires:
* - Slider control in the Flash library.
*/
import fl.controls.Slider;

var slider:Slider = new Slider();
slider.tickInterval = 1;
slider.move(20, 20);
addChild(slider);

No comments:

Post a Comment