TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Prakash Shrivastav
NA
73
3.2k
WPF c# Integration With Facebook and Share Image on Timeline
Sep 12 2018 10:09 AM
Hi,
I am integrating wpf c# application with facebook and share image on facebook timeline.
While i am doing my connection is successful, while i am removing scopes but when posting image on facebook timeline it shows error 200 and shows facebook deprecated the version to publish the images.
Now Share Dialog to Share images and for Native Desktop application :
https://developers.facebook.com/docs/facebook-login/for-devices
public void UploadContent()
{
string photoAlbumID = "199967900755629";
FacebookMediaObject facebookUploader = new FacebookMediaObject { FileName = "Carnival-Mask-Costume-Ideas-800x600.jpg", ContentType = "image/png" };
//var bytes = File.ReadAllBytes(System.IO.Path.GetDirectoryName(System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName) + "\\" + facebookUploader.FileName);
var bytes = File.ReadAllBytes(@"D:\Gallery\Carnival-Mask-Costume-Ideas-800x600.jpg");
facebookUploader.SetValue(bytes);
var postInfo = new Dictionary<string, object>();
postInfo.Add("message", "test photo");
postInfo.Add("image", facebookUploader);
postInfo.Add("access_token", fbtoken.AccessToken);
var fbResult = fbtoken.Post("/" + photoAlbumID + "/photos", postInfo);
dynamic result = (IDictionary<string, object>)fbResult;
}
Please help me out to connect facebook and share image on facebook timeline.
Facebook Appid and secret Key, Client Token I have.
Reply
Answers (
1
)
Implementing IOT using iPhone
jammer how to make a cell phone jammer