简体   繁体   English

如何从Flash Projector中安装AIR应用程序?

[英]How to install an AIR app from within a Flash Projector?

I have two files: 我有两个文件:

  1. A company demonstration file, created with CS5, flash projector file: demo.exe 使用CS5创建的公司演示文件,Flash投影仪文件:demo.exe
  2. A catalog application, created with Flash Builder 4.6, air file: catalog.air 使用Flash Builder 4.6创建的目录应用程序,空气文件:catalog.air

The distribution media is going to be CDROM. 分发媒体将是CDROM。 demo.exe file will, eventually, be setup as autorun file. demo.exe文件最终将被设置为自动运行文件。

I need to be able to install the air app if not previously installed, or run it directly if already installed from within the "demo.exe" file. 我需要能够安装air应用程序(如果先前未安装),或者如果已经从“ demo.exe”文件中安装了它,则可以直接运行它。

What I tried: 我试过的

  1. Downloaded air.swf for checking installed air application, 下载air.swf来检查已安装的空气应用程序,
  2. Exported demo.exe as "access local files only" 将demo.exe导出为“仅访问本地文件”

The Problem: 问题:

air.swf returns null for the installed version of catalog.air, so that I can't figure out if catalog.air is installed or not. air.swf对于所安装的catalog.air版本返回null,因此我无法确定是否安装了catalog.air。

The Overcome: 克服:

change "access local files only" to "acccess network only" and load air.swf from " http://airdownload.adobe.com/air/browserapi/air.swf " then it will detect the installed version correctly. 将“仅访问本地文件”更改为“仅访问网络”,然后从“ http://airdownload.adobe.com/air/browserapi/air.swf ”加载air.swf,它将正确检测安装的版本。

But then: 但是之后:

Switching to "access network only" mode will prevent accessing the local catalog.air file. 切换到“仅访问网络”模式将阻止访问本地catalog.air文件。 Hence, I can't get access to catalog.air and can't install it. 因此,我无法访问catalog.air并无法安装它。

I am running out of my deadline and pulling my hair. 我快要赶不上最后期限了,拔头发了。 Any hint pointing to right direction is mostly appreciated. 任何指向正确方向的提示都值得赞赏。


Update: Both flash and air app is using AS3. 更新:Flash和Air应用程序都使用AS3。

If you use AS1/2, try use fscommand ("exec", filename) , it may ignore "access network only" restriction. 如果您使用AS1 / 2,请尝试使用fscommand ("exec", filename) ,它可能会忽略“仅访问网络”限制。

fscommand ("exec", "catalog.air")

or 要么

fscommand ("exec", "installMyApp.bat") ( installMyApp.bat runs catalog.air ) fscommand ("exec", "installMyApp.bat")installMyApp.bat运行catalog.air

catalog.air/installMyApp.bat must be in fscommand dir near your demo.exe catalog.air/installMyApp.bat必须位于demo.exe附近的fscommand目录中

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM