Can NativeProcess.isSupported and Updater.isSupported both be true in an AIR application?
-
22-06-2021 - |
Question
I'm trying to check user domain name in Windows, and need native process support.
In the application config xml (xmlns="http://ns.adobe.com/air/application/2.6"
) I have
<supportedProfiles>extendedDesktop desktop</supportedProfiles>
When I run the application with adl everything works, but when I trying to installing the application (*.air package), I get an error that native proccess is not supported. Interesting that when I install the compiled *.exe file, after installation I have native processes support.
But with *.exe installation I have Updater.isSupported == false
, but, when I'm installing with *.air package I have Updater.isSupported == true
.
Looks like when I'm installing *.exe I have profile=extendedDesktop, but when I'm using *.air installation package I have using profile=desktop.
But I need both. Is there any way to solve this problem?
compilation:
echo Creating air application
call g:\flex_sdk\bin\adt.bat -package -storetype pkcs12 -keystore mykey.p12 -storepass simple -tsa none news.air news-app.xml .
echo Compile exe
call g:\flex_sdk\bin\adt.bat -package -target native news.exe news.air
Solution
What you are asking for is not possible. ApplicationUpdater
provided by Adobe does not work with native-code applications.
(You can see the code if you'd like more information on why; it is available in your sdk directory under \frameworks\projects\air\ApplicationUpdater\src
.)
However, it is possible to automatically update native-code packaged applications in a similar, though not completely identical, way. See this post on Adobe's website for more information: http://www.adobe.com/devnet/air/articles/updating-air-apps-native-installer.html. I would provide the information here, but I am not the author of that article.