在应用内建浏览器中打开安装APP界面

在应用内建浏览器中打开安装APP界面

需要先获取App在商店中的appID

- (void)openAppWithIdentifier:(NSString *)appId{
    SKStoreProductViewController *storeProductVC = [[SKStoreProductViewController alloc] init];
    storeProductVC.delegate = self;
    NSDictionary *dict = [NSDictionary dictionaryWithObject:appId forKey:SKStoreProductParameterITunesItemIdentifier];
    [storeProductVC loadProductWithParameters:dict completionBlock:nil];

    [self presentViewController:storeProductVC animated:YES completion:nil];
}

你可能感兴趣的:(在应用内建浏览器中打开安装APP界面)