I have a view in which I record sound using AVAudiorecorder and then it save to the document directory. And from another View I am playing the sound using AVAudioplayer from document directory. But the strange behavior is that AVaudioPlayer always not playing the sound, but in sometimes it play sound.
I have a view in which I record sound using AVAudiorecorder and then it
Share
Yes the problem is solved, I have to reinitialize the audio session to playbackCategory using the following code
Now it can always play the sound.