×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    Mar 2003
    Posts
    32

    How to put my app into the background...running there...

    Hi,

    I'd like to implement an app that switches into the background when I start it. It should run there and send events to applications. NO AUTOSTART! The user has to start the app manually.

    How can I implement that? What classes are needed? (Just to put my app into the background!)

    Thx.

  2. #2
    Registered User
    Join Date
    Mar 2003
    Posts
    25

    RE: How to put my app into the background...running there...

    I had a look at this problem and I resolved to use a client server approach.

    My plan is to have the server running in its own process (.exe) and provide clients with a library (.dll) that ease access and handling of the server calls. This is to my mind the most efficient way I've seen to achieve this.

    The advantage of this solution is to allow more than one client to use the server at any time.

    You can then view messages as being client request and server response. All of this using active objects.

    Hope this helps.

    GreG

  3. #3
    Nokia Developer Expert
    Join Date
    Mar 2003
    Posts
    271

    RE: How to put my app into the background...running there...

    Hi,

    Sounds like you need to write a server! But if you just want to implement the way you mentioned, here is some code to bring your application to the background:

    TApaTaskList taskList(iWsSession);
    TApaTask task = task.FindApp(_L("Your_App_Name&quot);

    // bring it to the background
    task.SendToBackground();

    However, it's up to you that where to place this loop so that when a user brings the app to the frontground, it will send itself to the background after a few second if the user does not want to terminate the task.

    Regards,
    FN Developer Support

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •