Categories: S60 | Symbian C++ | Code Examples | How To | Telephony
This page was last modified 11:23, 16 November 2007.
How to dial a string (with pause characters)
From Forum Nokia Wiki
The classes CPhCltDialer and TPhCltExtPhoneDialData provide methods for dialing a string. (The header files can be found in PhoneClientDialAPI & PhoneClientExtensionAPI, which are part of Extensions plug-in package for S60 3rd Edition SDK for Symbian OS, for C++, Maintenance Release. This package can be downloaded here.
With CTelephony classes you can only dial phone numbers (so numeric input only). Dialing a string i.e., a phone number with pause characters like 'p' or 'w' is not possible using CTelephony classes and is possible only using the above mentioned classes.
Ex: 121p2
Contents |
Header files
#include <CPhCltDialer.h> #include <BAUTILS.H> #include <CPhCltExtPhoneBase.h> #include <TPhCltExtPhoneDialData.h> #include <PhCltTypes.h>
Libraries used
phoneclient.lib efsrv.lib bafl.lib
Example code
void DialStringL( const TDesC& aNumber) { // Load the resource into CONE environment _LIT(KPhoneClientResourceFile, "z:\\resource\\PhoneClient.rsc"); TFileName resFile(KPhoneClientResourceFile); BaflUtils::NearestLanguageFile(CCoeEnv::Static()->FsSession(), resFile); const TInt offset = CCoeEnv::Static()->AddResourceFileL(resFile); // you need instance of CPhCltDialer CPhCltDialer* dialer = CPhCltDialer::NewL(); TPhCltTelephoneNumber phoneNumber(aNumber); TPhCltExtPhoneDialData& dialData = dialer->DialData(); // Set telephone number with pause character dialData.SetTelephoneNumber(phoneNumber); dialData.SetContactId(KPhCltNoContact); dialData.SetCallType(EPhCltVoice); dialer->ExecuteLD(); // Now remove the resource file lock CCoeEnv::Static()->DeleteResourceFile(offset); }
Example project
Example application to dial a string
| Related Discussions | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| reading Files. Please Help me | lpinguin | Mobile Java General | 3 | 2007-01-10 11:44 |
| I don't understand '"1\t"<0x6BCD><0x725B>' thingy in ***.LOC files... | advocatee | Symbian User Interface | 3 | 2003-08-26 03:50 |
| How to dial the extension number? | yanhongnokia | Symbian Tools & SDKs | 0 | 2003-06-05 22:38 |
| Incoming call on the Nokia 3410 | ludviglarsson | Mobile Java General | 3 | 2003-07-21 09:06 |
| 7650 drawstring limit of 200 characters | ggros | Mobile Java General | 0 | 2003-04-08 10:18 |
