Code Sample: Silverlight List Viewer

The Silverlight List Viewer sample for SharePoint 2010 creates a Microsoft Silverlight application that, when hosted on a SharePoint website, displays list items from that site.

Applies to: SharePoint Foundation 2010

Available in SharePoint Online

The sample creates a drop-down picker for selecting lists and displaying their contents within a dynamically generated Grid control. The sample shows how to use delegates for callback methods in asynchronous processing, and how to use a Dispatcher object to make changes in the SharePoint Foundation user interface.

Prerequisites:

  • Microsoft Visual Studio 2010

  • Microsoft SharePoint Foundation 2010

  • Microsoft Silverlight 3

Downloading and Using the Silverlight List Viewer Sample

  1. Download the Microsoft SharePoint 2010 Software Development Kit (SDK) from SharePoint 2010 Reference: Software Development Kit.

  2. Extract SilverlightListViewerSample.zip from the path %ProgramFiles%\Microsoft SDKs to a local folder.

  3. In the folder where you extracted the files, locate the SilverlightListViewerSample folder, and open the Readme.txt file.

  4. Follow the instructions in Readme.txt to use the sample.

See Also

Concepts

Using the Silverlight Object Model

Data Retrieval Overview

How to: Retrieve List Items

Common Programming Tasks in the Managed Client Object Model

Other Resources

SharePoint 2010 Client Object Model