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
Developer
Posts: 1,006
Registered: ‎05-22-2009
My Device: Not Specified

How to listening the System Events while application is not running in the background

Hi,

 

I want to know how to listen to system events like normal messages coming,Push Messages coming,Similar to timer task sort of thing to check out at the regular intervals.

 

Inorder to do this,i know way of creating NonUiApplication which runs in the background,listen to  incoming push messages,execute timer task at the regular intervals etc,

 

I want to know is there any way to do this without use of this NonUiApplication which can be identified while switching application ?

 

 

Thanks

 

Rakesh Shankar

 

Developer
Posts: 19,631
Registered: ‎07-14-2008
My Device: Not Specified

Re: How to listening the System Events while application is not running in the background

Does this help?

 

http://supportforums.blackberry.com/t5/Java-Development/Create-a-Background-Application/ta-p/445226

 

The other option is to override the Application method "acceptsForeground()". 

Developer
Posts: 1,006
Registered: ‎05-22-2009
My Device: Not Specified

Re: How to listening the System Events while application is not running in the background

Hi Peter,

 

When i do with above Link,Will it shown as non UiApplication in Switch Application Menu?

 

Regards

Rakesh Shankar

Highlighted
Developer
Posts: 16,750
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: How to listening the System Events while application is not running in the background

no, as it is an application, not an uiapplication
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter