wolfgang ziegler

„make stuff and blog about it“

Share to Facebook / Twitter / … from your Windows Phone App

July 25, 2012

The Windows Phone development tools make it really easy to share arbitrary messages to your favorite social network by providing the ShareStatusTask class.

Share Status
var shareStatusTask = new ShareStatusTask(); shareStatusTask.Status = "my awesome posting"; shareStatusTask.Show();

If you happen to be a fan of one-liners, like I do, you can boil down that code to that:

Share Status (one liner)
new ShareStatusTask() { Status = "my awesome posting" }.Show();

The result is the same in both cases.

image Sharing statuses programmatically could not be any simpler, right?