0

how to navigate to music-player of iPhone from my application in iOS using objective-c?

Jagdeep Singh
  • 2,556
  • 3
  • 18
  • 28

3 Answers3

0

You could also try the AVAudioPlayer utility Framework:

http://developer.apple.com/iPhone/library/documentation/AVFoundation/Reference/AVAudioPlayerClassReference/Reference/Reference.html

Abhinandan Pratap
  • 2,142
  • 1
  • 18
  • 39
0

you can do like this

if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"music://"]]) 
  [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"music://"]];

for iOS9 you need to integrate the LSApplicationQueriesSchemes in your .plist also , ref this link once

Community
  • 1
  • 1
Anbu.Karthik
  • 82,064
  • 23
  • 174
  • 143
0

You can open apps from your app by using iphone URL Schemes.

NSString *stringURL = @"music:";
NSURL *url = [NSURL URLWithString:stringURL];
[[UIApplication sharedApplication] openURL:url];

Check this Iphone_URL_Scheme post for more details. it have great explanation to how to open app from own app.

Hope this will help :)

Ketan Parmar
  • 27,092
  • 9
  • 50
  • 75