Flash Builder 4.5 Application SDK 2.6 Auto Update Fails
I have developed a few applications using Flex Builder 3 and have recently switched to using Flash Builder 4.5 for my air application developement of new applications. ApplicationUpdaterUI worked fine in FB3, but now in FB4.5 it fails with:
[StatusUpdateErrorEvent (type=updateError text=unknown update descriptor namespace id=16815 + subErrorID=0)]
My Application descriptor reads:
<application xmlns="http://ns.adobe.com/air/application/2.6">
So I changed my update descriptor in my Update.xml on the server from 1.0(for FB3) to 2.6 like so:
<update xmlns="http://ns.adobe.com/air/framework/update/description/2.6">
This give me the error above...
If I change the update descriptor to 2.5 like so:
<update xmlns="http://ns.adobe.com/air/framework/update/description/2.5">
I get the following Error:
[StatusUpdateErrorEvent (type=updateError text=Application namespace and update descriptor namespace are not compatible id=16831 + subErrorID=0)]
I have read in multiple forums that you need to switch the updater descriptor back to 2.5, or even back to 1.0. I have tried both of these, and it still will not work! Here is my updater code. I just put this flex component on the start state of my application. I believe this is all correct, but please fill me in if I am wrong...
<?xml version="1.0" encoding="utf-8"?>
<s:Group xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx" width="400" height="32"
creationComplete="checkForUpdate()">
<fx:Declarations>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>
<fx:Script>
<![CDATA[
import air.update.ApplicationUpdaterUI;
import air.update.events.StatusUpdateErrorEvent;
import air.update.events.UpdateEvent;
import flash.events.ErrorEvent;
import mx.controls.Alert;
private var appUpdater:ApplicationUpdaterUI = new ApplicationUpdaterUI();
private function checkForUpdate():void{
appUpdater.updateURL = "http://test.example.com/root/updates/update.xml";
appUpdater.isCheckForUpdateVisible = false;
appUpdater.addEventListener(UpdateEvent.INITIALIZED, onUpdate);
appUpdater.addEventListener(ErrorEvent.ERROR, onError);
appUpdater.addEventListener(StatusUpdateErrorEvent.UPDATE_ERROR, onUpdateError);
appUpdater.initialize();
}
private function onError(event:ErrorEvent):void{
Alert.show(event.toString());
}
private function onUpdate(event:UpdateEvent):void{
appUpdater.checkNow();
}
private function onUpdateError(event:ErrorEvent):void{
Alert.show(event.toString());
}
]]>
</fx:Script>
</s:Group>
And here is my update.xml...
<?xml version="1.0" encoding="utf-8"?>
<update xmlns="http://ns.adobe.com/air/framework/update/description/2.5">
<version>1.0.1</version>
<url>http://test.example.com/root/updates/Application_1.0.1.air</url>
<description><![CDATA[
1.0.1 (07/20/2011)
Testing the update code
]]></description>
</update>
PLEASE HELP!!
