Hi when I add a new component using Actionscript I want it to fade in smoothly, for example this component
var df : DateField = new DateField();
df.text = DateField.dateToString(new Date(),stringFormat);
df.formatString = stringFormat;
I tried this
var fade : Fade = new Fade();
df.setStyle("showEffect", fade);
but that did not work.
any ideas? =)
Thanks in advance
Sebastian
The showEffect is only triggered when you change the .visible property of the component – you need to trigger that somewhere to experience the awesomeness of the fade.
I threw this together real quick so you can see what I mean (also notice I used a string to define the fade rather than an object – it always seems easier that way…hope it helps!)