开发者

Communication between 2 Flex Playbook Applications

The overall aim of my project is to communicate between two Playbook flex applications. I found this article and tried it out:

http://supportforums.blackberry.com/t5/tkb/articleprintpage/tkb-id/tablet@tkb/article-id/20

Application 1 (Called 'App1')

var folder:File = File.applicationStorageDirectory.resolvePath("shared/misc");
folder.createDirectory();
employeeDB = File.applicationStorageDirectory.resolvePath('shared/misc/employee.db');

Application 2 (Called 'App2')

How do I access employee.db? I have tried the following which didn't work

employeeDB = File.applicationStorageDirectory.resolvePath('App1/shared/misc/employee.db');

and

employeeDB = File.applicationStorageDirectory.resolvePath('shared/misc/employee.db');

No luck, any ideas?

Answer

employeeDB = File.documentsDirectory.resolveP开发者_JAVA技巧ath('employee.db');

On both apps...


The applications are sandboxed. You cannot communicate with them in this way. The application storage directory is unique per application (and each application's storage directory is available only to that application).

Here is a forum post that explains some details of the sandboxing: http://www.blackberryplaybookforum.com/playbook-developers-area/43-playbook-application-file-system-layout-file-structure.html

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜