How to Share Link with the ShareLinkTask in Windows Phone ?

You can easily share the link from your Windows Phone App using the ShareLinkTask Launcher .

You could share link on FaceBook , Twitter , WindowsLive , LinkedIn etc.

How to Share Link with the ShareLinkTask in Windows Phone ?

To share link via Windows Phone App , follow the below steps

1. Include the namespace using Microsoft.Phone.Tasks;

This is the namespace where the Launchers are defined

2. Create an instance of ShareLinkTask and set the following property of the ShareLinkTask

  • Title – Title for the Link
  • Message – The status / message to be posted
  • LinkUri – The URL to be shared
private void button1_Click(object sender, RoutedEventArgs e)
{
ShareLinkTask shareLinkTask = new ShareLinkTask();
shareLinkTask.Title = "@WinPhoneRocks";
shareLinkTask.LinkUri = new Uri("http://developerpublish.com", UriKind.Absolute);
shareLinkTask.Message = "My Windows Phone website...";
shareLinkTask.Show();
}

3. Run the Application and click the button , you should see a form to share the Link …

How to Share Link with the ShareLinkTask in Windows Phone ?
How to Share Link with the ShareLinkTask in Windows Phone ?
How to Share Link with the ShareLinkTask in Windows Phone ?
How to Share Link with the ShareLinkTask in Windows Phone ?

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

In this post, you’ll learn about the Win32 Error “0x000019E5 – ERROR_COULD_NOT_RESIZE_LOG” that you get when debugging system erors in...
In this post, you’ll learn about the error “CO_E_DBERROR 0x8004E02B” that is returned when working with COM based APIs or...
In this post, you’ll learn about the Win32 Error “0x000019D0 – ERROR_LOG_BLOCK_VERSION” that you get when debugging system erors in...