简体   繁体   English

C#facebook graph /如何在Facebook相册上传图像?

[英]C# facebook graph / How to upload an image on Facebook album?

I am trying to upload an image using ASP.NET with C#.I do not how to send image in parameter source="F://sample.jpg".I have also tried to send an image in a byte format. 我正在尝试使用带有C#的ASP.NET上传图像。我不知道如何在参数source =“F://sample.jpg”中发送图像。我还尝试以字节格式发送图像。

URL is http://graph.facebook.com/album_id/photos?access_token=access_tokenvalue ; URL为http://graph.facebook.com/album_id/photos?access_token=access_tokenvalue ;

Post Data is 发布数据是

source= "F://sample.jpg" source =“F://sample.jpg”

I am getting an exception.Please help me to sort out this issue. 我得到了一个例外。请帮我解决这个问题。

Thanks in advance. 提前致谢。

Could you post the error message you're getting? 你能发贴你得到的错误信息吗? Might be helpful in tracking down exactly what the error is. 可能有助于准确追踪错误是什么。 In any case, I'm not too familiar with the Facebook APIs but it appears in the Graph API document for Photo that you have to prefix the file path with an @. 在任何情况下,我都不太熟悉Facebook API,但它出现在Photo的Graph API文档中,您必须在文件路径前加上@。

source="@F:\\sample.jpg"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM