我成功将照片发布到Twitter。但是,如何使用我的C#应用程序将视频发布到Twitter呢?发布图片我使用了Tweetsharp。我们可以使用Tweetsharp的SendTweetWithMediaOptions来分享视频吗?如果是的话如何?将视频发布到twitter
这是样品我用来分享图片到Twitter
Bitmap img = new Bitmap(Server.MapPath(@"~/Images/Special/" + Convert.ToInt32(offerId) + "/" + specialOffer.Picture));
MemoryStream ms = new MemoryStream();
img.Save(ms, System.Drawing.Imaging.ImageFormat.Jpeg);
ms.Seek(0, SeekOrigin.Begin);
Dictionary<string, Stream> images = new Dictionary<string, Stream> { { "mypicture", ms } };
var tweet = tweetservice.SendTweetWithMedia(new SendTweetWithMediaOptions { Status = urlTextToShare, Images = images });
和我需要的是像下面的图片
谁投下了这个问题请告诉我答案。 – 2014-08-28 07:19:48
你的问题含糊不清。你尝试过什么,它以什么方式不起作用。发布示例代码。 – 2014-08-28 07:25:01
我不知道该怎么做。这就是我在这里问这个问题的原因。如果你想引用我的照片发布代码,请看我编辑的问题。 – 2014-08-28 08:34:18