Working with AIR, files and XML configuration: tips & tricks

In last months I worked so hard with Flex, AIR and files. I’d like to share with you some tips that I think could save your time when you work on it.

 1. Don’t copy, write or do anything else with File.applicationDirectory. In Windows Vista, when you install an AIR application in Program folder, you can’t copy or update a file becuase Microsoft policy don’t allow to work on files in this directory and in all subdirectories.
If you try to make it, it fails silently so stop to execute the code immediately.

2.  You can’t set an <installFolder> different of Program or Application folder. If you try to set a different path like ../ or anything else in AIR configuration xml, when you create .air file, procedure fails with an error.
So you can only set Program folder (Windows) or Application folder (Mac) or a subdirectory like: Applications/myAirAppDir/

3. Attribute <programMenuFolder> is ONLY for Windows.
When you set this attribute you can choose path of Start/Programs menu. It’s optional attribute.

4. Remember to set <name> attribute without special chars.
If you try to make it, or you accidentally copy this attribute in the same XML configuration file, it fails with an error.

5. You can’t install AIR applications in a computer if you don’t have system privileges.

I hope that those suggestions could help in your daily development.

Advertisements

2 thoughts on “Working with AIR, files and XML configuration: tips & tricks

  1. hi luca,

    are you going to share your presentation files afterwards? I’m not able to make it to sotr, too bad 😦

    I’m finishing a mobile guide for sotr as well. I’ll let you know when its finished! 🙂

    grtz Thomas

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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 )

Google+ photo

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

Connecting to %s