Although the specification says that CMdaAudioPlayerUtility can play Wave, AMR, MIDI, AAC and Real Audio, it can not play the AMR file.

I used like following:


void ConstructL()
CMdaAudioPlayerUtility* iPlayerFile;
iPlayerFile = CMdaAudioPlayerUtility::NewFilePlayerL(KAmrFile,*this);

//Callback function
void CAudioPlayerEngine::MapcInitComplete(TInt aError, const TTimeIntervalMicroSeconds& /*aDuration*/)
if (aError == KErrNone)
iPlayerFile->SetVolume(iPlayerFile->MaxVolume() / KToneVolumeDenominator);

As soon as the iPlayerFile is constructed with the KAmrFile, Framework should call MapcInitComplete(..) function, where I should get kErrNone. Function always returned with error for AMR file. But If I use Wave file in:
iPlayerFile = CMdaAudioPlayerUtility::NewFilePlayerL(KWavFile,*this);
Then it plays the file. Meaning MapcInitComplete function is called with KErrNone. It seems like it can not evet open the AMR file. I tested MP3 which does not work as well.

Nokia has a documentation about using MMF where it is discussed about CMdaPlayerUtility. Please take a look at the following link: