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
New Developer
marcrh
Posts: 6
Registered: ‎10-14-2008
My Device: Not Specified
Accepted Solution

Permissions SDCard

I've developing an application that needs to read files from the SDCard frecuently, and there are no troubles while using the simulated device, but when I try to test the application over my 8310 Curbe every time that a file is accessed a message asking for the file access is showed, and I'm shure that the permissions to the application had been set to allow.

I've tryed to use some code extracted from the forum:

 


ApplicationPermissions permissions = new ApplicationPermissions();
permissions.addPermission(ApplicationPermissions.PERMISSION_FILE_API);
permissions.addPermission(ApplicationPermissions.PERMISSION_INTERNAL_CONNECTIONS);
permissions.addPermission(ApplicationPermissions.PERMISSION_LOCAL_CONNECTIONS);
if( ApplicationPermissionsManager.getInstance().invokePermissionsRequest( permissions )) {             
         System.out.println( "The user saved equal, or more permissive settings" );
} else {
         System.out.println( "The user saved more restrictive settings" );
}


This code show a Screen at the application startup wich I can set the permissions, but anyway it's showed as "allow".

 

I'm doing something wrong?

 

Thanks

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

Re: Permissions SDCard

What type of prompt are you seeing?  Please see this post for more information.

 

http://supportforums.blackberry.com/rim/board/message?board.id=java_dev&message.id=320&query.id=1687...

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
New Developer
marcrh
Posts: 6
Registered: ‎10-14-2008
My Device: Not Specified

Re: Permissions SDCard

Thanks I've to register all the keys.