J2ME App: Send HTTP post to webserver when phone is closed.

"Motorola i870"

My J2ME application sends HTTP post to the web server. It woks great when the phone is open. I need to send the HTTP message when the phone is closed. I would really appreciate if you could help me anyway.

Who is Participating?
The phone is essentially in a paused or suspended state when the phone is closed. You will not be able to initiate an POST when the phone is in this state. Some devices give you this capability (basically running a daemon thread), but the vast majority do not. While the i870 is very feature rich, they also do not have the capability to create a constantly running background thread.
velosumdevAuthor Commented:
Thank you for your tips. I have an application for Motorola i870. Is there anyway I can run the networking when the phone is closed, so that I could send the POST.
Not without some type of background thread and, as far as I know and read, this device does not have that capability. If you look at the specification for the MIDlet lifecycle, you'll see the paused/suspended state. You *might* be able to trigger a POST when the lid closes, but not after that event has passed -- at least not with the i870
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.