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
My Carrier: Verizon

Invocation error on BB10

Tried simple invocation to open a PDF file and I get the following trace error:

[qnx.pps.Message(invokeTarget dat: {
	uri : /accounts/1000/appdata/com.o2interactive.compass.bb10.debug.testDev__bb10_debug14a8b01c/shared/documents/test.pdf
}, peer : null, error : null, id: null, result: null]
INVOKE RESPONSE [qnx.pps.Message(invokeTarget dat: [null], peer : @control, error : INVOKE_NO_TARGET_ERROR, id: 1, result: invokeTarget]

 The code was llike:

var request :InvokeRequest = new InvokeRequest();
request.uri = file.nativePath;
			
InvokeManager.invokeManager.invoke( request );

 

Any thoughts?  Not working yet?

Please use plain text.
New Developer
cmax
Posts: 21
Registered: ‎04-19-2011
My Device: Blackberry Torch 9800
My Carrier: Rogers

Re: Invocation error on BB10

You're getting the INVOKE_NO_TARGET_ERROR becuase you need to specify a target in your invoke request

Please use plain text.
Developer
Developer
mdd
Posts: 224
Registered: ‎01-17-2012
My Device: PB
My Carrier: ATT

Re: Invocation error on BB10

do you have an application to read PDF's?

 

On (my) Dev Alpha simulator there is no such application...

 

Regards,

Please use plain text.
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Invocation error on BB10

I read that if no specific target is specified, that the registered system will pick one.

mdd is right, no PDF viewer. Guess that would help.
Please use plain text.
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Invocation error on BB10

I wrote a driver app so I can get the invocation to work.  In my driver app, I have:

var request :InvokeRequest = new InvokeRequest();
request.action = InvokeAction.OPEN;
request.target = 'com.o2interactive.compass.debug';
			
InvokeManager.invokeManager.invoke( request );

 I get this in debug:

[qnx.pps.Message(invokeTarget dat: {
	action : bb.action.OPEN
	target : com.o2interactive.compass.debug
}, peer : null, error : null, id: null, result: null]
INVOKE RESPONSE [qnx.pps.Message(invokeTarget dat: [null], peer : @control, error : INVOKE_NO_TARGET_ERROR, id: 1, result: invokeTarget]

 The app id is "com.o2interactive.compass", but since it is in debug, the BAR files has "com.o2interactive.compass.debug".

 

Does anyone know what needs to be done to trigger another app?

Please use plain text.
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Invocation error on BB10

Removed the action and I still get:

[qnx.pps.Message(invokeTarget dat: {
	target : com.o2interactive.compass.debug
}, peer : null, error : null, id: null, result: null]
INVOKE RESPONSE [qnx.pps.Message(invokeTarget dat: [null], peer : @control, error : INVOKE_NO_TARGET_ERROR, id: 1, result: invokeTarget]

 

Please use plain text.
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Invocation error on BB10

Ah. I assumed the "target" is the application id. It is not. It is the XML defined in the bar-descriptor.xml file as noted here.

https://developer.blackberry.com/cascades/documentation/device_platform/invocation/receiving_invocat...

I got my first invocation to work!
Please use plain text.