I want to add audio player in my app.I have no idea about it. I want to play songs and make playlist also...how can i do this?
Asked
Active
Viewed 3,384 times
-1
-
3try reading some documentation – Jim Rhodes Jan 17 '12 at 04:30
-
1But I am having no idea what should I refer? – khushbu shah Jan 17 '12 at 04:37
-
1try searching for AV.foundation in the Apple developer website – ChrisPadgham Jan 17 '12 at 04:45
-
My question is--can I run my application without simulator?I have created app but I am having warnings(not errors)and the app is not working....so,what you think....is it simulator prob?should I use device for this?help me please.. – khushbu shah Jan 20 '12 at 11:51
3 Answers
0
You can find tutorial from the following link:- http://mobileorchard.com/easy-audio-playback-with-avaudioplayer/
or
http://psychicparrotgames.com/?p=33
or
http://www.codeproject.com/KB/iPhone/abPlayer_iPhone.aspx
Hope it helps you.

Sunil Zalavadiya
- 1,993
- 25
- 36
0
go through following links, it will help you -
http://mobileorchard.com/easy-audio-playback-with-avaudioplayer/
http://mobile.tutsplus.com/tutorials/iphone/ios-sdk_background-audio/
0
do as below.
#import <AVFoundation/AVFoundation.h>
NSString *musicFilePath = [[NSBundle mainBundle] pathForResource:@"sample" ofType:@"mp3"];
NSURL *musicURL = [[NSURL alloc] initFileURLWithPath:musicFilePath];
AVAudioPlayer *player = [[AVAudioPlayer alloc] initWithContentsOfURL:musicURL error:nil];
[player prepareToPlay];
[player play];

kong
- 423
- 1
- 4
- 12