Interacting with the Web

In Chapter 6, you saw how you can use the WebClient class to download a file from the Web. This technique allows you to grab a resource or even a Silverlight assembly at the exact point in time when an application needs it.

The WebClient isn't just for downloading binary files. It also opens some possibilities for accessing HTML pages and web services. And using its bigger brother, WebRequest, you gain the ability to post values to a web page. In the following sections, you'll see a variety of approaches that use these classes to pull information from the Web. But before you begin, you need to reconsider the security limitations that Silverlight applies to any code that uses HTTP.

Note The networking examples in this ...

Get Pro Silverlight 5 in VB now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.