Adobe AIR的全球应用数据 [英] Adobe Air Global Application Data
问题描述
有谁知道Adobe AIR的全球应用程序的数据?
Does anyone know of a "Global" Application data for Adobe Air?
File.applicationStorageDirectory
用户区域内的商店?
但我们需要的应用程序存储信息为整个计算机。
But we need the application to store information for the whole computer.
东西如Windows:C:\ ProgramData或AllUsers的,但似乎并没有被使用,这些地区的官方途径。 (试图保持这种尽可能标准)
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 as possible)
但似乎没有成为一个 File.allUsersApplicationStorage
或 File.globalApplicationData什么。
But there doesn't seem to be a File.allUsersApplicationStorage
or File.globalApplicationData anything.
现在我知道我可以做一些事情,如下面的Windows Vista / 7
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");
但我不知道该怎么做的WinXP,MacOS的或Linux。
but I do not know what to do for WinXP, MacOS or Linux.
任何帮助将受到欢迎。
推荐答案
你不能只是使用 File.applicationDirectory
? (或者更确切地说,它的子目录中。),将存储在应用程序目录中的信息,并会从所有用户访问。
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.
这篇关于Adobe AIR的全球应用数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!