Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Adobe AIR Development

Reply
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10

Notification file link bad

Adding a notification like this:

var notification :Notification = new Notification();
notification.title = 'My Title';
notification.subTitle = 'My body';
notification.invokeAction = InvokeAction.OPEN;
notification.invokeTarget = 'com.o2interactive.my.app';

var file :File = File.documentsDirectory.resolvePath( '../downloads/' + 'mynotify.unique.xml' );

// add data to file

notification.invokeUri = 'file://' + file.nativePath;

 When the notification comes in and it is opened from the hub, the uri for the invocated notification is:

 

file:///accounts/1000/invoke/com.o2interactive.my.app/xa0000000000189/mynotify.unique.xml

 

And when testing if the file exists, it does not.  So it is not referencing the same file URI that was provided to it.  "isSymbolicLink" is false as well.

 

The only work around I see is to look for "invoke" in the URI, grab the file name and then get it from the saved location.

 

Any other suggestion?