Hi
After searching info in the forums,
I managed to play a WAV file after answering a voice call .
The problem is that the WAV is played to the loud speaker although the loud speaker is off.
I want the WAV to be played to the user's ear (like a regular voice call is heard) and not to the loud speaker (unless loud speaker is on).
Please advise - how can I do this ?
Any Info & Suggestions would be great :-)
Thank you very much
Here is the code I use :
Code:// ****** Calling Play method from Active class ****** CPlaySound * player = new CPlaySound(); player->Play(); // ****** PLAYSOUND.H ****** class CPlaySound : public CBase, public MMdaAudioPlayerCallback { public: virtual void MapcInitComplete(TInt aError, const TTimeIntervalMicroSeconds& aDuration); void Play(); virtual void MapcPlayComplete(TInt aError); private: CMdaAudioPlayerUtility* iAudioPlayer; }; // ****** PLAYSOUND.CPP ****** void CPlaySound::MapcInitComplete(TInt aError, const TTimeIntervalMicroSeconds& aDuration) {} void CPlaySound::Play() { iAudioPlayer = CMdaAudioPlayerUtility::NewFilePlayerL(_L("c:\\system\\data\\test.wav"), *this); iAudioPlayer->SetVolume(iAudioPlayer->MaxVolume()); iAudioPlayer->SetPriority(80,EMdaPriorityPreferenceTimeAndQuality); iAudioPlayer->Play(); } void CPlaySound::MapcPlayComplete(TInt aError) {}



