saigeethamn wrote:aibo99 wrote:1. User starts the RemoteServiceClient app, then clicks 'Start' button on UI to start the RemoteService thread remotely.
2. He just pushes 'Home' button on handset to leave the RemoteServiceClient app.
3. After several minutes, he starts the RemoteServiceClient app again, and clicks 'Start' button on UI to start the RemoteService.
My questions :
a) If the first instance of RemoteService still alive, will it create another instance of RemoteService in step 3 ? (how to avoid multiple instances created ?)
yes, the first remote service is still very much alive. if you come back and restart the client and click on the start button again, you will get a message that the remote service has already been started. It will not start another service unless the first one has been killed by the platform due to memory reasons. In case that has been killed, the start button will start a new service. You can make out the difference by seeing the counter. If it has been running for all the time the client moved away, when you come back and bind and invoke, it will give a large count.
Users browsing this forum: No registered users and 8 guests