1/23/2013 5:21:36 PM
2218
Reputation
300
Total posts
Hello super,
The following feature is not supported directly by MonoX and requires custom coding. We have developed similar features for custom projects however.
First please make sure that you are following these guidelines to create a custom MonoX based project.
Next you need to select an SDK you would like to use for your Facebook integration, we have used Facebook C# SDK. One of my coworkers wrote an article on this subject and you can read it here. The article will demonstrate you how to setup your own Facebook application and how to fetch users profile. This is a sample code which can be used to post a message on a users wall, please note that the sample is based on Facebook C# SDK:
/// <summary>
/// Posts a message to wall.
/// </summary>
/// <param name="accessToken">User access token.</param>
/// <param name="title">Message title.</param>
/// <param name="description">Message description.</param>
/// <param name="link">Message link.</param>
/// <param name="imageUrl">Custom image url.</param>
/// <returns></returns>
public
bool
PostMessageToWall(
string
accessToken,
string
title,
string
description,
string
link,
string
imageUrl)
{
Dictionary<
string
,
object
> args =
new
Dictionary<
string
,
object
>();
args[
"from"
] = ApplicationSettings.FacebookApplicationId;
// this would be your own application id which you obtain from facebook
args[
"description"
] = description;
args[
"name"
] = title;
args[
"link"
] = link;
args[
"picture"
] = imageUrl;
var obj = client.Post(
"/me/feed"
, args);
JsonObject post = obj
as
JsonObject;
if
(post !=
null
)
{
if
(post.ContainsKey(
"id"
) && post[
"id"
] !=
null
)
{
string
id = post[
"id"
].ToString();
if
(!
string
.IsNullOrWhiteSpace(id))
return
true
;
}
}
return
false
;
}
Now that we have covered the Facebook integration, here is a related
blog post.This article demonstrates the steps required to push blog posts to Blogger. The
MonoX implementation section will be of an interest to you since it explains the steps needed to push any blog post to an external service.
Regards,
Mario
Rating history (Content is rated 5.00 of 1 vote(s).)
Shows who have rated the content, and the rating score.