About This Book – SharePoint 2010 Web Parts in Action

About This Book

This book focuses on Web Part development in SharePoint 2010 using Visual Studio 2010. It takes you on a journey from learning what a Web Part is and how you can use Web Parts, to building your own Web Parts in different and advanced ways. When you have read it, you should be a fairly skilled SharePoint Web Part developer, ready to take on challenging projects.

How this book is organized

This book covers Web Part development from basic to advanced scenarios and is divided into three parts. Each chapter can stand on its own and you can use it as a reference when looking at a particular scenario.

The first part, consisting of chapters 1 and 2, is about Web Parts in general—to get you started. These two chapters explain the parts of a Web Part, how a Web Part fits into SharePoint, and how to use Web Parts in the SharePoint user interface, as well as in SharePoint Designer.

Part 2 is where the action begins. It consists of 11 chapters that start you off building basic Web Parts using Visual Studio 2010. You will learn how to build configurable and personalizable Web Parts and how to package and deploy them in a maintainable way. Once you have learned the basics, discussion of advanced topics in subsequent chapters, such as building contextual-aware and Silverlight Web Parts, will show you how to take your Web Parts one step further. One of these (chapter 8) is dedicated to troubleshooting; you will learn how to debug Web Parts and how to make troubleshooting easier—or avoid it entirely. New techniques introduced in SharePoint 2010, such as the Client Object Model, the Sandbox, and PowerShell are also covered. Part 2 ends with a chapter that focuses on design patterns and the latest guidelines released by Microsoft.

The third and final part (chapters 14 and 15) covers end-to-end scenarios where you learn how to connect Web Parts so that they interact with each other. In chapter 15 you learn how to deploy solutions of pre-configured site pages with connected Web Parts.

Finally, an appendix lists the most commonly used out-of-the-box Web Parts. For each Web Part, the corresponding class, feature, and its connection end-points are documented.

Who should read this book

SharePoint 2010 Web Parts in Action is a book for SharePoint developers. Web Parts is one of the core concepts of SharePoint and a requirement when you are building enterprise portal solutions. The book assumes that you have basic knowledge of SharePoint and development in ASP.NET using C#. Even if you’re already a skilled SharePoint developer you will find details that you haven’t seen before or even thought possible.

How to use this book

If you are new to SharePoint 2010 development you should read this book in order, from chapter 1 to the end. The first chapters will give you a good start and a smooth introduction to SharePoint Web Part development and Visual Studio. Experienced SharePoint developers should start with chapter 4. Even though this chapter may contain information that you already know, or think you know, it points out some commonly made mistakes. From there, the chapters will drill deeper and deeper into Web Part development. And you can always refer back to specific chapters when looking for a specific solution.

Code conventions and downloads

This book contains a lot of code listings and snippets. All compilable code is written using C# but since this is a SharePoint book you will also see XML snippets. All code is written using a fixed font like this, and if you are reading on an eReader or in PDF format, you will see that the code is color coded. Some code listings and snippets contain annotations to highlight important topics.

You can download the source code for many of the samples in this book from the publisher’s website at www.manning.com/SharePoint2010WebPartsinAction.

Software requirements

To take full advantage of this book you need to have a copy of SharePoint 2010 Foundation and Visual Studio 2010 (not the Express version). Preferably, you should have access to a virtual environment. Chapter 3 has detailed information about software requirements.

Author Online

The purchase of SharePoint 2010 Web Parts in Action includes access to a private forum run by Manning Publications where you can make comments about the book, ask technical questions, and receive help from the author and other users. To access and subscribe to the forum, point your browser to www.manning.com/SharePoint2010WebPartsinAction, and click the Author Online link. This page provides information on how to get on the forum once you are registered, what kind of help is available, and the rules of conduct in the forum.

Manning’s commitment to our readers is to provide a venue where a meaningful dialogue between individual readers and between readers and the author can take place. It’s not a commitment to any specific amount of participation on the part of the author, whose contribution to the book’s forum remains voluntary (and unpaid). We suggest you try asking the author some challenging questions, lest his interest stray!

The Author Online forum and the archives of previous discussions will be accessible from the publisher’s website as long as the book is in print.

About the author

Wictor Wilén is a SharePoint Architect at Connecta AB with more than 12 years of experience in the web content management and portal industry. He has worked for consulting companies, founded and sold his own software company, and experienced the beginnings of SharePoint back in 2001. He is an active SharePoint community participant, writer, tutor, and frequent speaker at local and international conferences. In 2010 Wictor was awarded the SharePoint Server MVP title by Microsoft for his community contributions. He can be found online at http://www.wictorwilen.se/. Wictor is based in Stockholm, Sweden.