I am trying to play dropbox uploaded sound file with AVAudioPlayer with below code.
-(void)initPlayerWithStreamingAudio:(NSString *)strAudioURL{
_audioPlayer = nil;
_audioPlayer=[[AVAudioPlayer alloc] initWithContentsOfURL:[NSURL fileURLWithPath:strAudioURL] error:NULL];
[[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback error:nil];
[[AVAudioSession sharedInstance] setActive: YES error: nil];
[self setAudioPLayerVolume];
_audioPlayer.numberOfLoops = 0;
[_audioPlayer play];
}
but _audipPlayer is nil.
so how can i play dropbox sound file url with AVAudioPlayer?
Any help will we appreciated.
Thanks in Advance
