Silverlight and Windows Phone 7 Now Supported

I’ve added support for Silverlight 4 and Windows Phone 7 to RestSharp. Please try it out and report back any errors or other feedback you have. You can download the latest revision here.

Here’s an example:

var client = new RestClient("http://example.com");
var request = new RestRequest("resource", Method.POST);

client.ExecuteAsync<Resource>(request, (response) => {
    var resource = response.Data;
});

As a side note, the core library is also now set to use the Client Profile by default. The Async methods from Silverlight/WP7 are also available in the core library as well.

Posted July 15th, 2:47 PM
Read more posts about Announcements, Samples, Silverlight, Windows Phone 7.

View Comments
Link

  • Ben
    I tried out the sample code and I get this issue:

    ErrorMessage = "The 'Content-Length' header cannot be modified directly.\r\nParameter name: name"

    I opened the windows phone 7 project, built the solution and adding the rest dll to my project. Am i missing something?
  • Melika
    Does this allow for maintaining cookies or no?
  • RestResponse.Cookies has all of the cookies returned from the server. Someone added a simple way to send them back in subsequent responses, but I need to track that down.
  • A simple way to re-send cookies would be great - I will log on github.
blog comments powered by Disqus