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
Posts: 2
Registered: ‎12-24-2008
My Device: Not Specified

How to auto-start the MIDlet after complete battery discharge?

 

HI,

 

Can MIDlet be auto-started even aftercomplete recharge of the battery if "auto invocation" was alreadyapproved before complete discharge of the battery and if yes, how?

 

Here is the scenario. I have developed a MIDlet using Netbeans and JDE 4.1.0. I was able toauto-start the MIDlet after adding to the Manifest and JAD files RIM-MIDlet-Flags-1:1 and approving "auto invocation" after answering"yes" to the prompt "The application <MIDlet name> hasattempted to register itself for auto invocation. Would you like to allowthis".

 

However it seems that the MIDlet auto-starts only if the batterywas not completely drained.

 

For example:

If I remove the battery and put it back then the MIDlet is not auto-started. If I start MIDlet manually and attempt to close it then the platform again displays the message to allow "auto invocation", despite that I confirmed it already before.

 

Thanks,

 

Zarick 

 

 

Developer
Posts: 5,339
Registered: ‎09-20-2008
My Device: ***
My Carrier: ***

Re: How to auto-start the MIDlet after complete battery discharge?

Auto-start feature works in different way.

 

It does not depend on battery charge level.

 

If your device can start, and device OS is loading, all of autostart applications will run in its turn.

 

Sooner or later (depends on run-level, set on jde project settings) - your application will run on startup if it is set as an "startup application".

 

To make sure that there are problems/or there is all right - use EventLogger class.

 

Write to device event log when your application starts.

 

To view event log press Alt on device keyboard, hold it and press LGLG

 

Device log will be opened, inspect it and find out what you need.