简体   繁体   English

Facebook API异常#100-C#中的无效参数

[英]facebook api exception #100-invalid parameter in c#

i developing a poster software, when i'm trying to post a link it give the following exception 我正在开发海报软件,当我尝试发布链接时,出现以下异常

facebook api exception #100-invalid Facebook API异常#100-无效

here's my code 这是我的代码

     public static bool post(string accesstoken,string status,string link) {
        try
        {
            FacebookClient fb = new FacebookClient(accesstoken);

            Dictionary<string, object> postArgs = new Dictionary<string, object>();
            postArgs["message"] = status;
            if (link != "") {
                postArgs["link"] = link;
                MessageBox.Show(link);
            }
            fb.Post("/me/feed", postArgs);
            return true;
        }
        catch (Exception ex)
        {
            MessageBox.Show(ex.ToString());
            return false;
        }
    }
}

you should check if the Stream post URL security option is on your app's dashboard, if it is turn it off: https://developers.facebook.com/apps , clic on settings and then migrations. 您应该检查应用程序的信息中心上是否有“信息流发布网址安全性”选项 (如果已关闭): https : //developers.facebook.com/apps ,请注意设置,然后进行迁移。

仪表板

See more information in the Migrations > Stream post URL security bullet : https://developers.facebook.com/docs/facebook-login/security#surfacearea 在“ 迁移”>“流发布URL”安全性公告中查看更多信息: https : //developers.facebook.com/docs/facebook-login/security#surfacearea

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

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