Home » Archive

Articles in the ActionScript 3.0 Category

ActionScript 3.0 »

[23 Jul 2012 | No Comment | ]

A simple AS3 Flash utility function to convert or get US state name from its abbreviation or US state abbreviation from its name.
Hope will be useful for the users.
Get US State abbreviation from State Name:
AS3 function to convert US-State name to its abbreviation.
AS3 Code and Usage:

function getStateToAbbreviationName( $state ):String
var resultStr:String =”";

if ($state==”Alaska”){ resultStr = “AK”; }
if ($state==”Alabama”){ resultStr = “AL”; }
if ($state==”Arkansas”){ resultStr = “AR”; }
if ($state==”Arizona”){ resultStr = “AZ”; }
if ($state==”California”){ resultStr = “CA”; }
if ($state==”Colorado”){ resultStr = “CO”; }
if ($state==”Connecticut”){ resultStr = “CT”; }
if ($state==”District of Columbia”){ resultStr = …

ActionScript 3.0, XML »

[20 Jul 2012 | No Comment | ]

In one of my Flash project i need to retrive twitter feed and update UI on new feed is available.
This is not a big task, any way below is the code might be useful for the beginners in AS3.
Compare XML and need to reload it and update UI if new XML is available.
Checking the XML feed in Timer Event and load it and compare with old feed.

AS3 Code :
Entire Code For loading Twitter feed and Check for new Updates
var timer:Timer = new Timer(15000,1);
timer.addEventListener(TimerEvent.TIMER_COMPLETE, handleTimerComplete)

var userName:String = “coolmobilesites”
var currentXML:XML;
var oldXML:XML;

function handleTimerComplete(e:TimerEvent):void


var …

ActionScript 3.0, Flash CS5 »

[19 Apr 2012 | No Comment | ]

Adobe Flash Player 11.3 Beta release provides access to the Flash Player 11.3 runtime for Windows, Mac OS and Linux desktop environments. The key features and benefits of Flash Player 11.3 are follow.
Also Check Flash player version installed
Flash Player 11.3 Beta features:
Full screen keyboard input
This feature enables support for all keyboard keys available to an embedded SWF running inside of a page without full screen mode( except for ‘Esc’). It allows developers to determine if the app is in full screen, whether full keyboard input is allowed, and whether …

ActionScript 3.0, AIR, Android »

[6 Apr 2012 | No Comment | ]

The beta release provides access to the AIR 3.3 runtime and SDK for Windows, Mac OS, iOS and Android.
The key features and benefits of AIR 3.3 are:
USB debugging for AIR iOS — This new feature allows the iOS developer to connect to the desktop via USB while debugging their mobile applications instead of relying on network connectivity.
Enhanced Background behavior for AIR iOS — Background support now more closely resembles native applications in iOS. In addition to some basic multitasking and background audio support that is already enabled with AIR for …

ActionScript 3.0, Flash CS5 »

[6 Jan 2012 | One Comment | ]

With as3 you can load variable from a text file into flash, here the tutorial explains how to achive with actionscript 3.0 Suppose we need use data which changes periodically can be edited in notepad and can be loaded in to Flash dynamically.

Basic – Intermediate

Setup text file with variables:
Before starting with actionscript or Flash first we need to setup the text file with variables. Text file should include name and value pair (name=value) seperated by ampersand ( & ).
Example of name and value pair:
Note: we can have any set of name and …