×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    Aug 2007
    Posts
    9

    Help! How to close all existing network connection?

    How can I close all the existing network connection created by other applictions.

    I know the s60 will close them when the user long press the red key on idle desktop.

    How to do it by program?

  2. #2
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Budapest, Hungary
    Posts
    28,572

    Re: Help! How to close all existing network connection?

    RConnection can do that for you. Enumerate, attach and stop one by one.

  3. #3
    Registered User
    Join Date
    Nov 2007
    Posts
    66

    Re: Help! How to close all existing network connection?

    Quote Originally Posted by slavikshen View Post
    How can I close all the existing network connection created by other applictions.

    I know the s60 will close them when the user long press the red key on idle desktop.

    How to do it by program?

    when i attach ,there will report -34

    what can i do to save this problem?
    my code:

    TBool connected(EFalse);TConnectionInfoBuf connInfo;TUint count;if ( connection.EnumerateConnections(count) == KErrNone ) { for (TUint i=1; i<=count; i++) { // Note: GetConnectionInfo expects 1-based index if ( connection.GetConnectionInfo( i, connInfo ) == KErrNone ) { if ( connInfo().iIapId == selectedIap ) { if ( connection.Attach(connInfo, RConnection::EAttachTypeNormal) == KErrNone ) { connected = ETrue; break; } } } } }

Similar Threads

  1. Initiate connection to an existing and paired HF device
    By romci in forum Bluetooth Technology
    Replies: 2
    Last Post: 2008-12-02, 00:28
  2. Nokia s60 SDK v2.0 - emulator network connection problem
    By eikka4 in forum Symbian Tools & SDKs
    Replies: 14
    Last Post: 2007-03-08, 06:53
  3. Unable to close connection
    By Kalderas in forum Symbian Networking & Messaging (Closed)
    Replies: 0
    Last Post: 2004-06-25, 13:43
  4. Using RGenericAgent to initiate Network connection?
    By mmalo in forum Symbian Networking & Messaging (Closed)
    Replies: 2
    Last Post: 2003-02-07, 16:39

Posting Permissions

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