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
Regular Contributor
amr3434
Posts: 81
Registered: ‎01-16-2012
My Device: BOLD 9650 + developer
My Carrier: Vodafone
Accepted Solution

How to lock app on device ??

if ther is any way to lock third party apps .?
i can list all the apps installed on the device  
i need to set password for it  when user trying to open it 

Please use plain text.
Developer
developer_aman_arora
Posts: 354
Registered: ‎06-05-2013
My Device: Blackberry Z10
My Carrier: Vodafone

Re: How to lock app on device ??

Make your own global screen
Please use plain text.
Regular Contributor
amr3434
Posts: 81
Registered: ‎01-16-2012
My Device: BOLD 9650 + developer
My Carrier: Vodafone

Re: How to lock app on device ??

is there is any steps how to do this or demo 

Please use plain text.
Developer
peter_strange
Posts: 19,599
Registered: ‎07-14-2008
My Device: Not Specified

Re: How to lock app on device ??

Can I recommend the use of the Search box before you ask a question like this.  You are not the first person who has tried to do this.  Below is one response I found while searching.  If you look, you will find Threads that give you more useful information than just telling you to create a global screen.

 

http://supportforums.blackberry.com/t5/Java-Development/Locking-Certain-Application/m-p/719993

Please use plain text.
Developer
developer_aman_arora
Posts: 354
Registered: ‎06-05-2013
My Device: Blackberry Z10
My Carrier: Vodafone

Re: How to lock app on device ??

[ Edited ]

One way is this:

private static int getAppBlock_id()	
{
int n = 0;
ApplicationDescriptor appDes[] = ApplicationManager.getApplicationManager().getVisibleApplications();
for(int i=0;i<appDes.length;i++)
{
if(appDes[i].getName().equals("Messages"))
{				
n=ApplicationManager.getApplicationManager().getProcessId(appDes[i]); break; } } return n; }

 use this in thread like this :

blockAppID = getAppBlock_id();
foregroundID = ApplicationManager.getApplicationManager().getForegroundProcessId();
if(blockAppID == foregroundID)
{
// Show Global Screen here
}

 Hit Like if you found your answer

Please use plain text.
Developer
rishikeshsinghpbh
Posts: 121
Registered: ‎05-31-2012
My Device: 9900
My Carrier: Airtel

Re: How to lock app on device ??

Please use plain text.