To package an .air file into a native installer you have to use a batch program called adt
.
The command on Windows
will look something like this:
C:\Users\jisaacks>"C:\Program Files (x86)\Adobe\Adobe Flash Builder 4\sdks\4.1.0\bin\adt" -package -target native "D:\DEV\Flex4\Workspaces\AIR Native Packager\AIRNIP\AIRNIP.exe" "D:\DEV\Flex4\Workspaces\AIR Native Packager\AIRNIP\AIRNIP.air"
I am trying to author a program in AIR that does this for you. Basically you drag/drop an .air file into it and it packages it into a native installer.
Well It gave me an Error #3219
error, which I looked up and found this:
AIR on Windows does not allow you to run .bat files directly. Windows .bat files are executed by the command interpreter application (cmd.exe). When you invoke a .bat file, this command application can interpret arguments passed to the command as additional applications to launch. A malicious injection of extra characters in the argument string could cause cmd.exe to execute a harmful or insecure application. For example, without proper data validation, your AIR application may call myBat.bat myArguments c:/evil.exe. The command application would launch the evil.exe application in addition to running your batch file.
If you call the start() method with a .bat file, the NativeProcess object throws an exception. The message property of the Error object contains the string "Error #3219: The NativeProcess could not be started."
I am wondering if there is a possible work around or if I have hit a brick wall?