zoukankan      html  css  js  c++  java
  • iOS 评论APP撰写评论

    ---- iOS 应用评分   

     

     UIAlertAction *alertAction1 = [UIAlertAction actionWithTitle:@"方式1 跳转到app商店" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {

            

            NSString *APPid = @"应用的ID";

            NSString *strloc = [NSString stringWithFormat: @"https://itunes.apple.com/us/app/qu-qi-wen-da/id%@?ls=1&mt=8",APPid];

            

            [[UIApplication sharedApplication] openURL:[NSURL URLWithString:strLoc]];

           

        }];

        

        UIAlertAction *alertAction2 = [UIAlertAction actionWithTitle:@"方式2 以模态跳转的方式应用内进行评分" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {

            SKStoreProductViewController *storeProductViewContorller = [[SKStoreProductViewController alloc] init];

            storeProductViewContorller.delegate = self;

            [storeProductViewContorller loadProductWithParameters: @{SKStoreProductParameterITunesItemIdentifier : @"应用的ID"} completionBlock:^(BOOL result, NSError *error) {

                

                if (result) {

                    [self presentViewController:storeProductViewContorller animated:YES completion:nil];

                }

            }];

        }];

        UIAlertAction *alertAction3 = [UIAlertAction actionWithTitle:@"残忍的拒绝" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {

            NSLog(@"残忍的拒绝");

        }];

        UIAlertController *alertController = [UIAlertController alertControllerWithTitle:@"”APP“评分" message:@"如果你觉得APP好用,可否为其评一个分数,评分过程只需花很少的时间,感谢您的支持!" preferredStyle:UIAlertControllerStyleActionSheet];

        

        [alertController addAction:alertAction1];

        [alertController addAction:alertAction2];

        [alertController addAction:alertAction3];

        [self presentViewController:alertController animated:YES completion:nil];

  • 相关阅读:
    javascript继承(对象冒充的多重继承)
    jQuery联动日历(一)
    jQuery联动日历(二)
    jQuery放大镜
    javascript快速排序
    jQuery倒计时
    打造一个自定义的echarts组件
    使用async返回promise<pending>状态的解决
    递归组件的小心得
    数论
  • 原文地址:https://www.cnblogs.com/wq-gril/p/4874946.html
Copyright © 2011-2022 走看看