Namespaces
Variants
Actions

How to send MIDlet to background

Jump to: navigation, search
Article Metadata

Article
Created: Aleksi (03 Apr 2007)
Last edited: hamishwillee (12 Jan 2012)

This articles shows how to use setCurrent(null) to send a foreground application to the background.

The setCurrent(null doesn't set the displayable to null but is used in Java ME implementations that support concurrent applications like S60 to send the foreground application to background (on Series 40 phones this approach does not work). The application that is shown is the last application that was shown before the MIDlet got activated. For example, if user launched the MIDlet from application shell just before then application shell is shown.

Following code can be used to send MIDlet to background:

Display display = Display.getDisplay(myMIDletClass);
display.setCurrent(null);

Comments

Reviewer-approved.png
21 Sep
2009
Article Review by vkmunjpara (20090921)

Level: Basic

As we know that computers have the capability to run applications in a concurrent mode. In S60 phones this can be possible. This article provides information regarding to this concept. A code is given in this article that is display.setCurrent(null); and it is well explained in this article.

This article is help full in every application.



Vikas.verma - background process

thanks for this. this is working and it's usefull in my application. i want to autostart in my application if mobile is on than auto my application is on so any one can help me for that to give me autostart process and sample code for autostart my midlet.



Vikas Verma

vikas.verma 11:10, 10 February 2012 (EET)

This page was last modified on 12 January 2012, at 06:12.
98 page views in the last 30 days.
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2012 All rights reserved