Post directly to facebook stream/wall with Androids Facebook SDK!

In my Android application I want to post something to facebook. I've played around A LOT with the facebook SDK and I can post to the wall, populate the dialog with a predefined string.

But right now I can't make it post directly to the "feed" or "stream". Right now the user can change the text that will be published to the wall. When the application has asked for the permission to post to the stream I want it to post it directly without that the user can change what it will say.

How do I do this?

Right now I have a class that implements DialogListener and the important code inside it looks like this:

Bundle parameters = new Bundle();

parameters.putString("message", "this is a test");

facebook.dialog(HighScoreActivity.this, "feed", parameters, this);


Make a call to the feed directly instead of calling the dialog.

AsyncFacebookRunner mAsyncRunner = new AsyncFacebookRunner(mFacebook);
mAsyncRunner.request("me/feed", params, "POST", new RequestListener() {
    // Where params is your Bundle
    // You would need to put here the required methods from RequestListener()
}

This would post directly to the feed, bypassing the dialog.

链接地址: http://www.djcxy.com/p/49602.html

上一篇: 在Android的Facebook墙上发布?

下一篇: 使用Androids Facebook SDK直接发布到Facebook流/墙!