You Are Here:

Community: Wiki

This page was last modified on 17 September 2009, at 05:47.

How to create access point

From Forum Nokia Wiki

Reviewer Approved   

If you want to create a new entry in the IAP table.

The code works fine.

#include commdb.h 
#include cdbcols.h
 
Link Against : commdb.lib
void CYourApp::SetNewIAP(TDesC8& aIAPName)
{
TUint32 aIAPId=0;
TInt aGPRSId=0;
TInt aId=0;
TInt aError;
 
TCommDbOpeningMethod aMethod;
static CCommsDatabase* aComDB =
CCommsDatabase::NewL(EDatabaseTypeIAP, aMethod);
CleanupStack::PushL(aComDB );
 
CCommsDbTableView* aView ;
 
aView = aComDB ->OpenTableLC(TPtrC(IAP));
CleanupStack::PushL(aView);
aError = aView->InsertRecord(iapId);
 
aView->WriteTextL(TPtrC(COMMDB_NAME), aIAPName);
aView->WriteTextL(TPtrC(IAP_SERVICE_TYPE), TPtrC(OUTGOING_GPRS));
aView->WriteUintL(TPtrC(IAP_SERVICE), aGPRSId);
aView->WriteUintL(TPtrC(IAP_NETWORK_WEIGHTING), 0);
aView->WriteUintL(TPtrC(IAP_NETWORK), aId);
aView->WriteUintL(TPtrC(IAP_BEARER), 0);
aView->WriteTextL(TPtrC(IAP_BEARER_TYPE), TPtrC(MODEM_BEARER));
aView->WriteUintL(TPtrC(IAP_LOCATION), 2);
 
aError = aView->PutRecordChanges(EFalse, EFalse);
 
CleanupStack::Pop(aComDB);
CleanupStack::Pop(aView);
delete aView;
delete aComDB;
}


Internal links

Related Wiki Articles

No related wiki articles found

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia 
RDF Facets: qdcZidentifierQSxhttpE3aE2fE2fwikiE2eforumE2enokiaE2ecomE2findeE78E2ephpE2fFileE3aMicrokernelE5fArchitectureE2eGIFX qdcZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qdcZtypeQUqfntypeZCommunityContentQ qdcZtypeQUqfntypeZE52esourceQ qdcZtypeQUqfntypeZWebpageQ qdcZtypeQUqfntypeZWikiContentQ qdcZtypeQUqmarsZManagedE52esourceQ qdcZtypeQUqwebZInformationE52esourceQ qdcZtypeQUqwebZPageQ qdcZtypeQUqwebZE52esourceQ qdcZtypeQUqrdfsZE52esourceQ qfnZtypeQUqfntypeZCommunityContentQ qfnZtypeQUqfntypeZE52esourceQ qfnZtypeQUqfntypeZWebpageQ qfnZtypeQUqfntypeZWikiContentQ qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX qrdfZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qrdfZtypeQUqfntypeZCommunityContentQ qrdfZtypeQUqfntypeZE52esourceQ qrdfZtypeQUqfntypeZWebpageQ qrdfZtypeQUqfntypeZWikiContentQ qrdfZtypeQUqmarsZManagedE52esourceQ qrdfZtypeQUqwebZInformationE52esourceQ qrdfZtypeQUqwebZPageQ qrdfZtypeQUqwebZE52esourceQ qrdfZtypeQUqrdfsZE52esourceQ