Hi,
Currently I am using wpf c# to integrate facebook and share image over facebook timeline or facebook wall
But when i use my code it will shows oauth error, depricated version you use, or some scopes has been removed by facebook
Currently facebook is using Share Dialog
Share Dialog
and for Desktop application :
Desktop or Native application
In Code
fbtoken
is the facebook client Object which i carry for token
and facebook rest detail with appid and secret key of my facebook app.
Please help me out.
What I have tried:
public void UploadContent()
{
string photoAlbumID = "199967900755629";
FacebookMediaObject facebookUploader = new FacebookMediaObject { FileName = "Carnival-Mask-Costume-Ideas-800x600.jpg", ContentType = "image/png" };
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;
}