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
Highlighted
Developer
Posts: 41
Registered: ‎07-07-2009
My Device: Not Specified
Accepted Solution

Close a running application or process

Hi, is there any command that I  can perform to close a running application or process? Maybe through process id? Or send a close notification to the application? Thanks!

 

 

Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: Close a running application or process

You can send a close notification to another application, provided that it knows how to interpret the event.

 

So, if you want to write application A which notifies Application B to close, you will have to place code in Applicaiton A to post the event, and Application B to listen for a global event (that you define), and react accordingly.

 

If you want to send such a notificaiton to any arbitrary applicaiton (like a RIM app), then no, this will not work. There is no standard "kill thyself" event defined.

 

Take a look at ApplicationManager.postGlobalEvent() and GlobalEventListener for more details.