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

Java Development

Reply
Contributor
yespay
Posts: 10
Registered: ‎09-19-2011
My Device: bold 9900

Card reading in bold9900 using NFC

I am using the sample application provided by blackberry, "nfcreaderdemo", to read a magstripe card. The application works fine when used separately.

But when I integrate it with my application it gives a "ControlledAccessException". I've also set all the permissions as specified in some forums.

But I am still not able to run the application. I see no solution of this exception.

Please tell me the solution to avoid the exception.

BlackBerry Development Advisor
MSohm
Posts: 14,757
Registered: ‎07-09-2008
My Device: BlackBerry Passport

Re: Card reading in bold9900 using NFC

Are you testing in the BlackBerry smartphone simulator or on a real device?  If it is a real device, how was the application installed?

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Contributor
yespay
Posts: 10
Registered: ‎09-19-2011
My Device: bold 9900

Re: Card reading in bold9900 using NFC

We are running on bold 9900 as I mentioned, and we used debugging function of eclipse to test the app on device.

 

The nfc reading app runs smoothly when run alone but gives the exception when integrated with another app.

 

Thanks in advance

BlackBerry Development Advisor
MSohm
Posts: 14,757
Registered: ‎07-09-2008
My Device: BlackBerry Passport

Re: Card reading in bold9900 using NFC

Using the Run/Debug As or Load onto Device features of Eclipse can cause issues with application permissions, which lead to false ControlledAccessExceptions.  Try loading through any other means (other than javaloader and specifying the COD file names).

 

This should be fixed in the next update of our plug-in.

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Retired
mwoolley
Posts: 571
Registered: ‎06-25-2010
My Device: Z10

Re: Card reading in bold9900 using NFC

This is probably caused by a known issue which is fixed in later device software builds:

 

- 9900 (Bold): fixed in OS version 7.0.0.337 (bundle 1603)
- 9360 (Curve) fixed at 7.0.0.360 (bundle 1699).

See http://supportforums.blackberry.com/t5/Java-Development/Listener-belongs-to-another-application-modu...


--------------------------------------------------------------------------------------------
Feel free to press the like button on the right side if you liked my attempts to help :-)
And please mark posts as solved if you think I found the solution or set you on its path. Thanks!
Follow me on Twitter: @mdwrim