我想通過我的Android應用程序使用Facebook SDK發佈圖像/文字在Facebook上。是否可以通過編程方式將我的Facebook頁面標記爲?我怎麼能標記我的Facebook的帖子與我的Facebook的頁面在Android
這裏是我的代碼:
SharePhoto photo = new SharePhoto.Builder()
.setBitmap(bitmap)
.setCaption(shareText)
.setUserGenerated(false)
.build();
SharePhotoContent content = new SharePhotoContent.Builder()
.addPhoto(photo)
.build();
ShareApi.share(content, new FacebookCallback<Sharer.Result>() {
}
我試圖打開圖形爲好。沒有任何事情發生,即使沒有對話顯示在Facebook上發佈。以下是代碼:
List<String> peopleIds = new ArrayList<String>(1);
peopleIds.add("AaJa_TfLYQJXLuTCQyNBG3dHoK7WCtpXePE1_qBFVPcNB68_KyGTRTXxjKWg6L1qbStB75WSEZ8OAmRxjbA");
SharePhoto photo = new SharePhoto.Builder()
.setBitmap(bitmapWaterMark)
.setCaption(shareText)
.setUserGenerated(true)
.build();
ShareOpenGraphObject object = new ShareOpenGraphObject.Builder()
.putString("og:type", "aaa")
.putString("og:title", "bbb")
.putString("og:description", "ccc")
.putString("books:isbn", "ddd")
.build();
ShareOpenGraphAction action = new ShareOpenGraphAction.Builder()
.putObject("book", object)
.putPhoto("image", photo)
.build();
ShareOpenGraphContent content = new ShareOpenGraphContent.Builder()
.setPreviewPropertyName("book")
.setAction(action)
.setPeopleIds(peopleIds)
.build();
ShareDialog.show(UploadFunnyContentActivity.this, content);
你能幫我分享通過開放圖來支持標記嗎? –