QUICKSTARTS
[This topic is pre-release documentation and is subject to change in future releases of Microsoft Silverlight.]

Networking and Communication in Silverlight

Introduction

Microsoft Silverlight-based applications can communicate with a Web service by using managed code. An application can transmit and receive data to and from the Web service. The communication can be performed by using the WebClient class or by using a WCF proxy to a Web service. HTTP request/response and a simplified version of it are supported through WebClient – this is how you do POX, JSON, and RSS. Aside from using HTTP request and response, you can also use generated proxies using "Add Service Reference" functionality.

Data can only be transmitted asynchronously.

note

Silverlight-based applications can either make calls back to their origin server or optionally make cross-domain calls. To enable cross-domain access on a service, it must provide a Clientaccesspolicy.xml or Crossdomain.xml file at the root of the domain.

In This Section

Receiving Plain XML Messages with Silverlight

Demonstrates how to use the HTTP transport to send and receive plain XML messages.

Building a WCF Web Service and Accessing It by Using a Proxy

Demonstrates the use of a proxy to communicate with a Windows Communication Foundation Web service, and shows how to configure the service correctly to be accessed by the proxy.

Accessing Syndication Feeds with Silverlight

Demonstrates how to access syndication feeds from a Silverlight-based application.

See Also

  • HttpWebRequest
  • HttpWebResponse
Page view counter