Adobe Air Global Application Data
Does anyone know of a "Global" Application data for Adobe Air?
File.applicationStorageDirectory
stores within the users area?
But we need the application to store information for the whole computer.
Something such as Windows: C:\ProgramData or AllUsers but there doesn't seem to be an official way to use these areas. (Trying to keep this as Standard开发者_如何学C as possible)
But there doesn't seem to be a File.allUsersApplicationStorage
or File.globalApplicationData anything.
Now I know I could do something such as below for Windows Vista/7
var _path:String = File.applicationDirectory.nativePath;
// _np: C:\Program Files (x86)\ProgName\
_path = _path.substr(0, _np.indexOf(File.separator) + 1);
// _np: C:\
var _file = new File(_path).resolvePath("ProgramData/ProgName");
but I do not know what to do for WinXP, MacOS or Linux.
Any help would be welcome.
Couldn't you just use File.applicationDirectory
? (Or rather, a subdirectory of it.) That would store your information in the application directory, and would be accessible from all users.
It might not be ideal, but it works.
精彩评论