Saturday, July 21, 2007

Retrieving Phone's Manufacturer ,Model & IMEI number Using CTelephony

---- Header --------
CTelephony* iTel;
CTelephony:: TPhoneIdV1Pckg iInfoPkg;
CTelephony:: TPhoneIdV1 iInfo;


---- CPP File ------

void Request()
{
iTel=CTelephony::NewL();
iTel->GetPhoneId(iStatus,iInfoPkg);
SetActive();
}

void RunL()
{
switch(iStatus.Int())
{
case KErrNone:
{
TBuf
CTelephony::KPhoneModelIdSize + CTelephony::KPhoneSerialNumberSize> phoneInfo;
phoneInfo.Copy(iInfo.iManufacturer);
phoneInfo.Append(iInfo.iModel);
phoneInfo.Append(iInfo..iSerialNumber);
}
break;
default:
{
//Return error
}
break;
}
}

No comments:

stats counter