While researching the question youre we can conclude that this is a rather rare case, which may be associated with the wrong product identifier in the case of SkProductViewController . You should also check if you want to show one application or the number of them. Because Apple has an error related to showing multiple items.
I am using SKStoreProductViewController this way. This is the code that shows the application on the App Store:
SKStoreProductViewController *storeProductViewController = [[SKStoreProductViewController alloc] init]; [storeProductViewController setDelegate:self]; [storeProductViewController loadProductWithParameters:@{SKStoreProductParameterITunesItemIdentifier : @"xxxxx"} completionBlock:^(BOOL result, NSError *error) { if (error) { NSLog(@"Error %@ with User Info %@.", error, [error userInfo]); } else { [self presentViewController:storeProductViewController animated:YES completion:nil]; } }];
Then I use the delegate SKStoreProductViewControllerDelegate as follows:
- (void)productViewControllerDidFinish:(SKStoreProductViewController *)viewController { [self dismissViewControllerAnimated:YES completion:nil]; }
I also use [button setExclusiveTouch:YES]; , because customers click several product buttons several times. Also check that you are id if it is a separate product.
Oleg Gordiichuk
source share