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

Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.

BlackBerry Development Advisor
Posts: 15,885
Registered: ‎07-09-2008
My Device: BlackBerry PRIV
My Carrier: Bell

Inter VM communication on BlackBerry

Quote from the previous forums:


Posts: 1
From: Ireland
Registered: Jul, 2008

Inter VM communication on BlackBerry
Posted: Jul 18, 2008 1:52 PM
Hello all,

I am writting two applications which will reside on the same blackberry device, one of the applications will be issuing the event, say wakeup event, sleep event and so on, whereas the other is the event listener and also taking the action according the type of the event, I am wondering what is the best way to achieve this in Blackberry enironment?

Any help is much appreciated.


You can use GlobalEvents and GlobalEventListeners to accomplish this.  Please see the link below for more information.


What Is - Global Events and Global Event Listeners
Article Number: DB-00145


Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
New Developer
Posts: 6
Registered: ‎07-18-2008
My Device: Not Specified

Re: Inter VM communication on BlackBerry

Hello msohm

Thank you very much for the response, but 'Global Events and Global Event Listeners' does not work for Midlet application, my Event listenser is inherited from Midlet application, not UiApplication, any thoughts?

Posts: 191
Registered: ‎04-03-2008
My Device: Bold 9700

Re: Inter VM communication on BlackBerry

Borrowing a page from Symbian development, you could implement interprocess communication between two processes by having one process bind to a port as a server and the other process send messages to that port as a client (this is a way to do IPC between a native Symbian app and a J2ME app).


Check out the SocketConnection and ServerSocketConnection javadocs.

Posts: 28
Registered: ‎07-24-2008
My Device: Not Specified

Re: Inter VM communication on BlackBerry

How about using the runtime store?



interface Listener { void doStuff(); } // distpatcher application RuntimeStore runtime = RuntimeStore.getRuntimeStore(); listener = (Listener)runtime.get(RUNTIME_ID); listener.doStuff(); // ... // listener application class Poo implements Listener { public Poo() { RuntimeStore runtime = RuntimeStore.getRuntimeStore(); runtime.put(RUNTIME_ID, this); } // ... }