×

Discussion Board

Results 1 to 9 of 9
  1. #1
    Registered User
    Join Date
    Sep 2003
    Location
    Mumbai, India
    Posts
    25

    Unhappy CommDB - Which IAP Id is the right IAP Id??

    Hi There,
    CommDB issues are back again! I am working on Automatic IAP Connections using RGenericAgent & RConnection.

    When I retrieve the IAP Ids from the CommDB using the OUTGOING_GPRS table; the attempt works perfectly. If the IAP settings are completely deleted and then requested again; then the pop-up starts appearing again on a call to RGenericAgent::StartOutgoing() or RConnection::Start().

    I shifted to the Connection Preferences table to retrieve the IAP after that. The IAP Id returned by that worked under all circumstances (i.e.:- No popup of dialog). But that only returns the Default IAP. I need the entire list of available GPRS IAPs for my application.

    It seems that the COMMDB_ID returned by the OUTGOING_GPRS table is not the right one which has to be passed to the Agent. I have also tried suing the WAP_ACCESS_POINT table but to no avail!

    The definition of a CommDB Id seems to be quite vague. I was under the assumption that the COMMDB_ID (which is in a lot of tables) is the IAP Id too which can be used for making automatic connections.

    Could someone PLEASE give me some idea as to which table will give me usuable IAP Ids (in relation to RGenericAgent & RConnection).

    Best Regards,
    Varun

  2. #2
    Registered User
    Join Date
    May 2005
    Posts
    4
    Here is part of my code:

    RConnection iConnection;
    TCommDbConnPref iConnPref;

    iConnPref.SetDirection( ECommDbConnectionDirectionOutgoing );
    iConnPref.SetDialogPreference( ECommDbDialogPrefDoNotPrompt );
    iConnPref.SetIapId( aIapId );
    //iConnPref.SetNetId( aIapId );
    iConnPref.SetBearerSet( KCommDbBearerUnknown );

    iConnection.Start( iConnPref, iStatus );

    It works in nokia6630.

    the aIapId is found in IAP table'a COMMDB_ID.

  3. #3
    Regular Contributor
    Join Date
    Nov 2004
    Location
    INDIA
    Posts
    84
    Hi,
    help me to findout aIapId from IAP table'a COMMDB_ID

    rgds,
    mani

  4. #4
    Registered User
    Join Date
    May 2005
    Posts
    4
    CCommsDbTableView* aTableView;
    TInt aResult;

    if ( aName.Length() > KCommsDbSvrMaxColumnNameLength )
    {
    return EFalse;
    }

    aTableView = aCommDb->OpenViewMatchingTextLC( TPtrC(IAP), TPtrC(COMMDB_NAME), aName );
    if ( NULL == aTableView )
    {
    return EFalse;
    }

    aResult = aTableView->GotoFirstRecord();
    if ( KErrNone == aResult )
    {
    aTableView->ReadUintL( TPtrC(COMMDB_ID), aId );
    CleanupStack::PopAndDestroy( aTableView );
    aTableView = NULL;
    return ETrue;
    }
    else
    {
    CleanupStack::PopAndDestroy( aTableView );
    aTableView = NULL;
    return EFalse;
    }



    It is said that U'd better use the CApSelect to query commdb.
    You can study for more.

    http://www.newlc.com/article.php3?id...rche=capselect

  5. #5
    Regular Contributor
    Join Date
    Nov 2004
    Location
    INDIA
    Posts
    84
    Hi,
    thanks for your help hiwangwang.
    when i go through your code ,i found that you are reading IAP table,COMMDB_NAME column,with the matching parameter aName.
    in IAP TABLE there is no column name like COMMDB_NAME
    this is iap table i got from ceddump.
    ############################################################
    ## IAP
    ##
    [IAP]
    ADD_SECTION
    # COMMDB_ID = 1
    Name=LAN_IAP_1
    IAPService=1
    IAPServiceType=LANService
    IAPBearer=1
    IAPBearerType=LANBearer
    IAPNetwork=1
    IAPNetworkWeighting=0
    Location=3
    FIELD_COUNT=8
    END_ADD

    ADD_SECTION
    # COMMDB_ID = 2
    Name=NTRas GPRS
    IAPService=1
    IAPServiceType=OutgoingGPRS
    IAPBearer=2
    IAPBearerType=ModemBearer
    IAPNetwork=1
    IAPNetworkWeighting=0
    Location=4
    FIELD_COUNT=8
    END_ADD

    ADD_SECTION
    # COMMDB_ID = 3
    Name=test
    IAPService=2
    IAPServiceType=OutgoingGPRS
    IAPBearer=0
    IAPBearerType=ModemBearer
    IAPNetwork=2
    IAPNetworkWeighting=0
    Location=4
    FIELD_COUNT=8
    END_ADD


    ############################################################
    ## ConnectionPreferences
    ##
    [ConnectionPreferences]
    ADD_SECTION
    Ranking=1
    Direction=OUTGOING
    DialogPref=PROMPT
    BearerSet=LAN
    IAP=1
    FIELD_COUNT=5
    END_ADD

    i dont know whether i have to use iap table or ConnectionPreferences table to be used for connecting internet automatically without prompting iap selection dialog.

    if iap table is to be used then my doubts are
    how to find the default access point from the records
    what is the text in aName variable
    what is the text in KCommsDbSvrMaxColumnNameLength

    if ConnectionPreferences table is to be used then my doubts are
    i think ConnectionPreferences is not a table,then how can i access the IAP column.

    i need my program to get a html page automatically without iap selection dialog.
    i am using RHTTPsession,rhttptransaction,rhttpresponse class for this program.
    how can i set
    iConnPref.SetIapId( aIapId );
    i need alapid value .please help me out

    rgds,
    mani

  6. #6
    Registered User
    Join Date
    May 2005
    Posts
    4
    COMMDB_NAME is a macro, the value is "Name". U can find out it in the file /include/cdbcols.h

    There is a example for U.
    http://db.cs.helsinki.fi/~mraento/lx...ectioninit.cpp

  7. #7
    Registered User
    Join Date
    Mar 2003
    Posts
    26
    My application only use RSocket and RSocketServ,
    not using RConnection.
    How can I attach TCommDbConnPref to RSocket?

  8. #8
    Registered User
    Join Date
    May 2005
    Posts
    4
    I think you could not implement it without rconnection

  9. #9
    Registered User
    Join Date
    Apr 2009
    Posts
    1

    Re: CommDB - Which IAP Id is the right IAP Id??

    Hi,
    I am trying to define a new IAP in the IAP table with IAPServiceType = CDMA2000PacketServiceTable.

    I have also defined the data for the table CDMA2000PacketServiceTable in the configuration file.

    But when i create the CommsDat file using the ced.exe i don't the new IAP listed with the other default IAPs. What could be possible wrong here?

Posting Permissions

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