![]() |
Run Application in Background
Hello Everyone
I have an application with user interface and it implements PhoneListener. I want to run that application in the background and bring in front when user selects from the icon or from swtich tab. How do I achive this? Thanks |
So your class looks like the following?
Code:
public class MyClass extends UiApplication implements PhoneListener |
Thanks for the input zechariahs.
I know how to implement PhoneListener. I want to run the application in the background and bring to front when user selects the icon or from swtich tab. Thanks |
Try this How To - Setup an alternate entry point for my application.
Quote:
|
Thanks zechariahs.
I understand what is explained in the document. But, what do I need to do from application getting closed using "Close" menu. Thanks |
From a user perspective, I would be pretty ticked if I couldn't close an application if I wanted to. Personally, I would override the onClose() method to prompt the user: "Are you sure you want to close? Yes | No | Cancel."
Also, if you really want to prevent the user from closing the application, override the onClose method to always return false. |
Thanks zechariahs.
Thats what I did. |
To put an application in the background call Application.requestBackground(), possibly as mentioned in the onClose() method.
|
I too need the same idea, that i have an icon When i am pressing the icon, i need to invoke an sms application which is running background. When i am exiting and later on coming bak , i need to keep the same screen alive , from where i exit.
|
if anyone knows pleas provide a sample code too..
Thanks |
Hi pravi
You just need to override the onClose() method for doing that, as mentioned above. |
All times are GMT -5. The time now is 01:40 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.