Posts tagged actionscript 3.0

How to change a textfields alpha in Actionscript 3.0

I am writing this tutorial for anyone who is having any issues with changing the alpha channel with actionscript. I’m gonna show you how. This might seem pretty straight forward at first, I mean I thought it was, but you actually can’t just start changing the alpha property without first setting its blendMode. This sometimes gets overlooked in tutorials.

First import the BlendMode Class into your document.

import flash.display.BlendMode;

Second you’ll want to set the textfields blendmode to LAYER

var myTextField:TextField = new TextField();
myTextField.blendMode = BlendMode.LAYER;

There it is fellas. Easy Breezy. Now you can change the alpha of the myTextField

If you liked this post, you might also like…

How to embed fonts in Actionscript 3.0 – the easy way

Simple Image Gallery in Flash CS4

Simple Image Gallery in Flash CS4

Want to create a cool image gallery in flash? Then this tutorial is perfect for you! This will teach you how to create a simple image gallery with thumbnails in Adobe Flash CS4.

Click Here for the Tutorial