iOS每日一记 -----之友盟社会化分享(微信和朋友圈)

友盟 分享啊。。。。。其实 不难的 跟着官方文档走 一步步来 很简单  主要的代码就这几句话、、、、

   NSLog(@"分享功能");
    NSString *shareText = _news.ni_title;
    [UMSocialSnsService presentSnsIconSheetView:self appKey:nil
                                      shareText:shareText
                                 shareImage:ImageNamed(@"icon_about_app_icon")
                                shareToSnsNames:[NSArray arrayWithObjects:UMShareToWechatSession,UMShareToWechatTimeline,nil]
                                       delegate:self];
    [UMSocialData defaultData].extConfig.wechatSessionData.url = self.Url;
    [UMSocialData defaultData].extConfig.wechatTimelineData.url = self.Url;
    NSString *title = @"NiHao";
   [UMSocialData defaultData].extConfig.wechatSessionData.title = title;
    [UMSocialData defaultData].extConfig.wechatTimelineData.title = title;



你可能感兴趣的:(ios,微信,友盟,社会化)