Cherr Skees
Cherr Skees

Reputation: 1518

Link to app from within xcode

Need button to link to other app in the app store. I use this...

[[UIApplication sharedApplication] 
  openURL:[NSURL URLWithString:@“http://www.google.com"]];    

it works fine in safari. From what I read if you want to link to the itunes store directly you use: itms-apps://ax.itunes.apple.com/WebObjects/MZStore.woa/wa/viewContentsUserReviews?type=Purple+Software&id=409954448

Whenever I do that it says invalid url. Maybe its because the app store isn’t available in the simulator? and it will only work on a device? Is there any way to test these links in the simulator?

I’m using http://itunes.apple.com/linkmaker/ to get the link to the app. Thanks for your input.

Upvotes: 4

Views: 3523

Answers (1)

Filip Radelic
Filip Radelic

Reputation: 26683

You have answered your own question here:

Whenever I do that it says invalid url. Maybe its because the app store isn’t available in the simulator? and it will only work on a device?

iOS Simulator doesn't have AppStore/iTunes and therefore can't open AppStore/iTunes links. But the way you do it is correct and should work without issues.

Upvotes: 6

Related Questions