Schemaphic Systems Blog

Sharing experiences in Flash, Flex and AIR

AIR Application Updater

leave a comment »

Look for “<version>” tag in the Application-app.xml file which gets generated while creating a WindowedApplication. The value of this tag resembles the current version of the air.

import air.update.ApplicationUpdaterUI;

var applicationUpdater:ApplicationUpdaterUI;

* Check to see if application update is required
public function checkForApplicationUpdate() : void
applicationUpdater = new ApplicationUpdaterUI();
applicationUpdater.updateURL = “update.xml”;//sample update.xml is provided below
applicationUpdater.isCheckForUpdateVisible = false;
applicationUpdater.addEventListener( UpdateEvent.INITIALIZED, onUpdateInitHandler );
applicationUpdater.addEventListener( ErrorEvent.ERROR, onErrorHandler );
applicationUpdater.addEventListener( StatusFileUpdateErrorEvent.FILE_UPDATE_ERROR, onErrorHandler );

private function onUpdateInitHandler( event:UpdateEvent ) : void
/*checkNow API actually compares the version of the current
installed application from Application-app.xml
with the version from update.xml and acts accordingly.*/

private function onErrorHandler( event:Event ) : void



<?xml version=”1.0″ encoding=”utf-8″?>
<update xmlns=”″&gt;
* These notes are displayed to the user in the update dialog
* Typically, this is used to summarize what’s new in the release


Written by Deepanjan Das

July 20, 2010 at 12:26 PM

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: