I am trying to launch an appstore page with either of the calls:
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://itunes.apple.com/us/app/myappname/id999999999?mt=8"]];
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"htt开发者_开发技巧p://www.itunes.com/apps/myappname"]];
Both of these urls work when I enter them in a browser. However, from both simulator and device, I get a "Your request could not be completed" error dialog right after it appears to try to launch the appstore.
Is there something obvious that I'm doing wrong?
I think I see what is going on. I believe the problem is that I'm testing the url with an existent iPhone app. When I go to launch it from my iPad app, it disallows it because the app doesn't work on iPad.
精彩评论