sharepoint › download › 0000 › 5889 › 17 › l... · 2013-07-23 · sharepoint is a...

30
Ken Withee President, Portal Integrators LLC Learn to: Understand how SharePoint 2010 has redefined development Develop SharePoint solutions without writing a single line of code Understand when to use which SharePoint tool Boost productivity through SharePoint 2010 and Microsoft Office integration SharePoint ® 2010 Development Making Everything Easier! Microsoft ®

Upload: others

Post on 07-Jul-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Ken WitheePresident, Portal Integrators LLC

Learn to:• Understand how SharePoint 2010 has

redefined development

• Develop SharePoint solutions without writing a single line of code

• Understand when to use which SharePoint tool

• Boost productivity through SharePoint 2010 and Microsoft Office integration

SharePoint® 2010 Development

Making Everything Easier!™

Visit the companion Web site at http://www.dummies.

com/go/sharepoint2010developmentfd for code

samples that you can use to create more advanced

SharePoint solutions

Open the book and find:

• How SharePoint Online saves you money

• Tips on working with Web parts

• Hints for customizing with master pages

• How to go farther with SharePoint Designer

• Advice on building dashboards, scorecards, and KPIs

• What you can add with a little bit of code

• How to automate SharePoint tasks

• Ten ways to reduce your business costs with SharePoint

Ken Withee is a consultant specializing in Microsoft SharePoint and

Business Intelligence. A Microsoft Certified Technology Specialist,

he is also the author of Microsoft Business Intelligence For Dummies and

a coauthor of Professional Microsoft SQL Server 2008 Reporting Services.

$29.99 US / $35.99 CN / £21.99 UK

ISBN 978-0-470-88868-1

Internet/Portal Development

Go to Dummies.com®

for videos, step-by-step examples, how-to articles, or to shop!

Power to the people! Create solutions geared to your business with SharePoint tools If you can use a Web browser, you can develop a SharePoint solution — and you don’t even have to be a programmer! SharePoint is a platform with many different pieces that help you accomplish things with your data. This friendly guide demystifies SharePoint, giving you the tools to create solutions to meet your business’s needs.

• Understand SharePoint — grasp the differences between SharePoint Foundation and SharePoint Server

• In the cloud — learn how SharePoint Online facilitates your business solutions, simplifies implementation, and provides essential services

• Browse your options — use your Web browser as a development environment for pages and mobile sites

• Services galore — explore how Excel Services and InfoPath Form Services help you manage reports and important business forms

• More tools — discover what you can do with SharePoint Designer, Report Builder, Visual Studio, and Dashboard Designer

SharePoint® 2010 D

evelopm

ent

Microsoft®Micro

soft

®

Withee

Page 2: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Start with FREE Cheat SheetsCheat Sheets include • Checklists • Charts • Common Instructions • And Other Good Stuff!

Get Smart at Dummies.com Dummies.com makes your life easier with 1,000s of answers on everything from removing wallpaper to using the latest version of Windows.

Check out our • Videos • Illustrated Articles • Step-by-Step Instructions

Plus, each month you can win valuable prizes by entering our Dummies.com sweepstakes. *

Want a weekly dose of Dummies? Sign up for Newsletters on • Digital Photography • Microsoft Windows & Office • Personal Finance & Investing • Health & Wellness • Computing, iPods & Cell Phones • eBay • Internet • Food, Home & Garden

Find out “HOW” at Dummies.com

*Sweepstakes not currently available in all countries; visit Dummies.com for official rules.

Get More and Do More at Dummies.com®

To access the Cheat Sheet created specifically for this book, go to www.dummies.com/cheatsheet/sharepoint2010development Mobile Apps

There’s a Dummies App for This and ThatWith more than 200 million books in print and over 1,600 unique titles, Dummies is a global leader in how-to information. Now you can get the same great Dummies information in an App. With topics such as Wine, Spanish, Digital Photography, Certification, and more, you’ll have instant access to the topics you need to know in a format you can trust.

To get information on all our Dummies apps, visit the following:

www.Dummies.com/go/mobile from your computer.

www.Dummies.com/go/iphone/apps from your phone.

Page 3: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

SharePoint® 2010 Development®

FOR

DUMmIES‰

01_9780470888681-ffirs.indd i01_9780470888681-ffirs.indd i 1/27/11 5:50 PM1/27/11 5:50 PM

Page 4: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

01_9780470888681-ffirs.indd ii01_9780470888681-ffirs.indd ii 1/27/11 5:50 PM1/27/11 5:50 PM

Page 5: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

by Ken Withee

SharePoint® 2010 Development®

FOR

DUMmIES‰

01_9780470888681-ffirs.indd iii01_9780470888681-ffirs.indd iii 1/27/11 5:50 PM1/27/11 5:50 PM

Page 6: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

SharePoint® 2010 Development For Dummies®

Published byWiley Publishing, Inc.111 River StreetHoboken, NJ 07030-5774www.wiley.com

Copyright © 2011 by Wiley Publishing, Inc., Indianapolis, Indiana

Published by Wiley Publishing, Inc., Indianapolis, Indiana

Published simultaneously in Canada

No part of this publication may be reproduced, stored in a retrieval system or transmitted in any form or by any means, electronic, mechanical, photocopying, recording, scanning or otherwise, except as permit-ted under Sections 107 or 108 of the 1976 United States Copyright Act, without either the prior written permission of the Publisher, or authorization through payment of the appropriate per-copy fee to the Copyright Clearance Center, 222 Rosewood Drive, Danvers, MA 01923, (978) 750-8400, fax (978) 646-8600. Requests to the Publisher for permission should be addressed to the Permissions Department, John Wiley & Sons, Inc., 111 River Street, Hoboken, NJ 07030, (201) 748-6011, fax (201) 748-6008, or online at http://www.wiley.com/go/permissions.

Trademarks: Wiley, the Wiley Publishing logo, For Dummies, the Dummies Man logo, A Reference for the Rest of Us!, The Dummies Way, Dummies Daily, The Fun and Easy Way, Dummies.com, Making Everything Easier, and related trade dress are trademarks or registered trademarks of John Wiley & Sons, Inc. and/or its affi liates in the United States and other countries, and may not be used without written permission. Microsoft and SharePoint are registered trademarks of Microsoft Corporation. All other trademarks are the property of their respective owners. Wiley Publishing, Inc., is not associated with any product or vendor mentioned in this book.

LIMIT OF LIABILITY/DISCLAIMER OF WARRANTY: THE PUBLISHER AND THE AUTHOR MAKE NO REPRESENTATIONS OR WARRANTIES WITH RESPECT TO THE ACCURACY OR COMPLETENESS OF THE CONTENTS OF THIS WORK AND SPECIFICALLY DISCLAIM ALL WARRANTIES, INCLUDING WITH-OUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE. NO WARRANTY MAY BE CREATED OR EXTENDED BY SALES OR PROMOTIONAL MATERIALS. THE ADVICE AND STRATEGIES CONTAINED HEREIN MAY NOT BE SUITABLE FOR EVERY SITUATION. THIS WORK IS SOLD WITH THE UNDERSTANDING THAT THE PUBLISHER IS NOT ENGAGED IN RENDERING LEGAL, ACCOUNTING, OR OTHER PROFESSIONAL SERVICES. IF PROFESSIONAL ASSISTANCE IS REQUIRED, THE SERVICES OF A COMPETENT PROFESSIONAL PERSON SHOULD BE SOUGHT. NEITHER THE PUBLISHER NOR THE AUTHOR SHALL BE LIABLE FOR DAMAGES ARISING HEREFROM. THE FACT THAT AN ORGANIZA-TION OR WEBSITE IS REFERRED TO IN THIS WORK AS A CITATION AND/OR A POTENTIAL SOURCE OF FURTHER INFORMATION DOES NOT MEAN THAT THE AUTHOR OR THE PUBLISHER ENDORSES THE INFORMATION THE ORGANIZATION OR WEBSITE MAY PROVIDE OR RECOMMENDATIONS IT MAY MAKE. FURTHER, READERS SHOULD BE AWARE THAT INTERNET WEBSITES LISTED IN THIS WORK MAY HAVE CHANGED OR DISAPPEARED BETWEEN WHEN THIS WORK WAS WRITTEN AND WHEN IT IS READ.

For general information on our other products and services, please contact our Customer Care Department within the U.S. at 877-762-2974, outside the U.S. at 317-572-3993, or fax 317-572-4002.

For technical support, please visit www.wiley.com/techsupport.

Wiley also publishes its books in a variety of electronic formats. Some content that appears in print may not be available in electronic books.

Library of Congress Control Number is available from the publisher upon request.

ISBN: 978-0-470-88868-1

Manufactured in the United States of America

10 9 8 7 6 5 4 3 2 1

01_9780470888681-ffirs.indd iv01_9780470888681-ffirs.indd iv 1/27/11 5:50 PM1/27/11 5:50 PM

Page 7: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

About the AuthorKen Withee is President of Portal Integrators LLC (www.portalintegrators.com), a professional services fi rm specializing in Microsoft SharePoint, SharePoint Online, and Microsoft Offi ce 365. He lives with his wife Rosemarie in Seattle, Washington. He is author of Microsoft Business Intelligence For Dummies and coauthor of Professional Microsoft SQL Server 2008 Reporting Services (WROX).

Ken earned a Master of Science degree in Computer Science studying under Dr. Edward Lank at San Francisco State University.

Ken has more than 12 years of professional computer and management experience working with a vast range of technologies. He is a Microsoft Certifi ed Technology Specialist and is certifi ed in SharePoint, SQL Server, and .NET.

01_9780470888681-ffirs.indd v01_9780470888681-ffirs.indd v 1/27/11 5:50 PM1/27/11 5:50 PM

Page 8: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

01_9780470888681-ffirs.indd vi01_9780470888681-ffirs.indd vi 1/27/11 5:50 PM1/27/11 5:50 PM

Page 9: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

DedicationI dedicate this book to my wife and best friend, Rosemarie Withee, who encouraged me daily throughout this time-intensive process. I owe her another year’s worth of late nights and weekends and hope to make it up to her during our long future together. I love you!

Author’s AcknowledgmentsI would like to acknowledge my grandma Tiny Withee who turns 98 this year and is still going strong. I would also like to acknowledge my wife Rosemarie Withee, mother Maggie Blair, father Ken Withee, sister Kate Henneinke, and parents-in-law Alfonso and Lourdes Supetran and family.

Thank s to Katie Feltman, Rebecca Huehls, Barry Childs-Helton, Mike Talley, and the rest of the For Dummies team for providing more support than I ever thought possible. It is truly amazing how much work goes into a single book.

01_9780470888681-ffirs.indd vii01_9780470888681-ffirs.indd vii 1/27/11 5:50 PM1/27/11 5:50 PM

Page 10: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Publisher’s Acknowledgments

We’re proud of this book; please send us your comments at http://dummies.custhelp.com. For other comments, please contact our Customer Care Department within the U.S. at 877-762-2974, out-side the U.S. at 317-572-3993, or fax 317-572-4002.

Some of the people who helped bring this book to market include the following:

Acquisitions, Editorial, and Media

Development

Project Editor: Rebecca Huehls

Senior Acquisitions Editor: Katie Feltman

Senior Copy Editor: Barry Childs-Helton

Technical Editor: Mike Talley

Editorial Manager: Leah P. Cameron

Media Development Assistant Project

Manager: Jenny Swisher

Editorial Assistant: Amanda Graham

Sr. Editorial Assistant: Cherie Case

Cartoons: Rich Tennant (www.the5thwave.com)

Composition Services

Project Coordinator: Katherine Crocker

Layout and Graphics: Samantha K. Cherolis

Proofreaders: Jessica Kramer, The Well-Chosen Word

Indexer: Broccoli Information Mgt.

Publishing and Editorial for Technology Dummies

Richard Swadley, Vice President and Executive Group Publisher

Andy Cummings, Vice President and Publisher

Mary Bednarek, Executive Acquisitions Director

Mary C. Corder, Editorial Director

Publishing for Consumer Dummies

Diane Graves Steele, Vice President and Publisher

Composition Services

Debbie Stailey, Director of Composition Services

01_9780470888681-ffirs.indd viii01_9780470888681-ffirs.indd viii 1/27/11 5:50 PM1/27/11 5:50 PM

Page 11: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Contents at a GlanceIntroduction ................................................................ 1

Part I: Understanding the SharePoint Development Platform .................................................. 5Chapter 1: Understanding the SharePoint Hype ............................................................ 7Chapter 2: SharePoint Online ......................................................................................... 17Chapter 3: SharePoint Development Overview............................................................ 25

Part II: Developing with Your Web Browser and Microsoft Office .................................................. 35Chapter 4: Developing Sites with Your Web Browser ................................................. 37Chapter 5: Taking Excel to a New Level with SharePoint ........................................... 77Chapter 6: Collecting Information with InfoPath ....................................................... 107Chapter 7: Integrating Visio and Word with SharePoint ........................................... 139

Part III: Exploring Standalone SharePoint Development Tools ................................................... 167Chapter 8: Using SharePoint Designer to Make Your Sites Sing .............................. 169Chapter 9: Developing Reports with Report Builder ................................................ 199Chapter 10: PerformancePoint Development with Dashboard Designer ............... 221

Part IV: Unleashing the Programmer Within .............. 247Chapter 11: SharePoint Development with Visual Studio ........................................ 249Chapter 12: Commanding SharePoint through Code ................................................ 265Chapter 13: Developing Web Par ts .............................................................................. 291Chapter 14: Working from the PowerShell Command Line ...................................... 309

Part V: The Part of Tens ........................................... 327Chapter 15: Top Ten Tools for SharePoint Development ......................................... 329Chapter 16: Ten Places to Go for SharePoint Development Information ............... 339Chapter 17: Ten Ways to Reduce Business Costs through SharePoint

Development ................................................................................................................ 345

Glossar y of SharePoint Development Terms ................ 357

Index ...................................................................... 365

02_9780470888681-ftoc.indd ix02_9780470888681-ftoc.indd ix 1/27/11 5:50 PM1/27/11 5:50 PM

Page 12: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

02_9780470888681-ftoc.indd x02_9780470888681-ftoc.indd x 1/27/11 5:50 PM1/27/11 5:50 PM

Page 13: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Table of Contents

Introduction ................................................................. 1About This Book .............................................................................................. 2How to Use This Book ..................................................................................... 2How This Book Is Organized .......................................................................... 2

Part I: Understanding the SharePoint Development Landscape...... 3Part II: Developing with Your Web Browser and

Microsoft Offi ce .................................................................................. 3Part III: Exploring Standalone SharePoint Development Tools ........ 3Part IV: Unleashing the Programmer Within ...................................... 4Part V: The Part of Tens ........................................................................ 4

Icons Used In This Book ................................................................................. 4

Part I: Understanding the SharePoint Development Platform ...................................................................... 5

Chapter 1: Understanding the SharePoint Hype . . . . . . . . . . . . . . . . . . . .7

Everyone Can Be a SharePoint Developer .................................................... 8Tracing the Origins of SharePoint ................................................................. 9So What Exactly Is SharePoint, Anyway? ...................................................... 9

Starting with the roots — computer hardware ................................ 10Software that talks to the hardware — the operating system ....... 12Software frameworks and servers — .NET and IIS .......................... 12A computer language for the Web — ASP.NET ................................ 13The fi rst step into the SharePoint world — SharePoint

Foundation ........................................................................................ 14A fi nished product — SharePoint Server .......................................... 14Untangling the versions and editions of SharePoint ....................... 15Climbing the SharePoint development ladder ................................. 16

Chapter 2: SharePoint Online. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .17

Introducing SharePoint Online .................................................................... 18Why SharePoint Online Is Becoming So Popular ....................................... 20Exploring the Benefi ts of SharePoint Online .............................................. 21

Data center and hardware .................................................................. 22Software platform ................................................................................ 23Backup, redundancy, and security .................................................... 23

Figuring Out Where SharePoint Online Is Going ........................................ 24

02_9780470888681-ftoc.indd xi02_9780470888681-ftoc.indd xi 1/27/11 5:50 PM1/27/11 5:50 PM

Page 14: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

SharePoint 2010 Development For Dummies xiiChapter 3: SharePoint Development Overview . . . . . . . . . . . . . . . . . . .25

Redefi ning What It Means to Be a Developer ............................................. 26Types of SharePoint Development .............................................................. 26

Meet your good friend, the Web browser ......................................... 26Exploring the SharePoint tools .......................................................... 27Getting down to the DNA level with programming.......................... 27

SharePoint Development Tools ................................................................... 28Cracking open the Web browser ....................................................... 28Microsoft Offi ce tools .......................................................................... 29Standalone tools .................................................................................. 31Programming tools .............................................................................. 33

Part II: Developing with Your Web Browser and Microsoft Office ......................................................... 35

Chapter 4: Developing Sites with Your Web Browser . . . . . . . . . . . . .37

Creating a SharePoint Site ............................................................................ 38Looking for a wheel instead of reinventing one ............................... 39Starting with a blank slate .................................................................. 43

Developing SharePoint Pages ...................................................................... 44Introducing the types of SharePoint pages ...................................... 44Master pages, application pages, and site pages............................. 45Grasping page-creation basics ........................................................... 46Creating a content page ...................................................................... 47Dragging-and-dropping your way to a Web Part page .................... 51Creating a publishing page ................................................................. 55

Developing Your Own Navigation ............................................................... 56Wrangling Data on Your Pages .................................................................... 59

Knowing your list options ................................................................... 59Checking out the available libraries .................................................. 61Creating a list or library ...................................................................... 63Developing a list ................................................................................... 64Packaging groups of site columns with content types ................... 66

Developing a Custom Look and Feel ........................................................... 68Applying a theme to your site ............................................................ 68Importing an Offi ce theme into SharePoint ...................................... 69Creating themes with Theme Builder................................................ 70Changing the master page .................................................................. 71

Reusing Your Development Efforts with Templates ................................. 73Saving a site as a template .................................................................. 73Activating a site template ................................................................... 74Saving lists and libraries as templates .............................................. 75

02_9780470888681-ftoc.indd xii02_9780470888681-ftoc.indd xii 1/27/11 5:50 PM1/27/11 5:50 PM

Page 15: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

xiii Table of Contents

Chapter 5: Taking Excel to a New Level with SharePoint . . . . . . . . . .77

Providing a Home for Spreadsheets in SharePoint ................................... 78Moving Excel into your SharePoint site ............................................ 78Publishing only pieces of Excel .......................................................... 82

Editing an Excel Spreadsheet from the Browser ....................................... 83Developing Data-Analysis Applications with Excel ................................... 86

Flipping data around with PivotTables ............................................. 86Slicing up the data ............................................................................... 90Gorging on data with PowerPivot ...................................................... 91Analyzing OLAP cube data with Excel............................................... 95Creating visualizations with Excel ..................................................... 96

Revving Up SharePoint with Excel Services ............................................... 98Tallying results with Excel Calculation Services ............................. 98Embedding a spreadsheet with Excel Web Access ......................... 98Excel Web Services ............................................................................ 101

Chapter 6: Collecting Information with InfoPath . . . . . . . . . . . . . . . . .107

Designing Dazzling Forms with InfoPath .................................................. 108Starting with the InfoPath Ribbon ................................................... 109Making a form Web-capable ............................................................. 110Designing a form’s look and feel ...................................................... 111Making forms smarter using rules and views................................. 117Making forms communicate with data connections ..................... 119Understanding form templates ........................................................ 120Building an address submission form ............................................. 121Starting out the easy way with templates....................................... 125Reusing form functionality with template parts ............................ 128

Making InfoPath Available in SharePoint with Form Services ............... 129Embedding forms in SharePoint pages ........................................... 130Creating form libraries ...................................................................... 131Customizing SharePoint list forms .................................................. 134Choosing List forms versus Library forms ..................................... 135Requiring approval for forms ........................................................... 136

Adding Code to InfoPath Forms ................................................................. 137

Chapter 7: Integrating Visio and Word with SharePoint. . . . . . . . . . .139

Making Visio Diagrams Available to Everyone with Visio Services ...... 140Embedding a Visio diagram .............................................................. 140Linking Web Parts in a Visio diagram.............................................. 143

Extending a Visio Web Drawing Using JavaScript ................................... 144Collaborating on Workfl ows with Visio and SharePoint ......................... 146

Creating a picture from a workfl ow ................................................. 147Creating a workfl ow from a picture ................................................. 150Visualizing the progress of a workfl ow ........................................... 151

Creating a Visio Process Repository in SharePoint ................................ 153

02_9780470888681-ftoc.indd xiii02_9780470888681-ftoc.indd xiii 1/27/11 5:50 PM1/27/11 5:50 PM

Page 16: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

SharePoint 2010 Development For Dummies xivUsing Word in a SharePoint World ............................................................ 154

Setting up libraries for Word documents ....................................... 156Server properties in Word ................................................................ 159

Working with Word from the Browser ...................................................... 162Introducing Word Automation Services in SharePoint ........................... 164

Part III: Exploring Standalone SharePoint Development Tools .................................................... 167

Chapter 8: Using SharePoint Designer to Make Your Sites Sing . . .169

Peering into the Looking Glass with SharePoint Designer ..................... 170Taking a Spin around SharePoint Designer .............................................. 172

Finding site-creation tools ................................................................ 172Unwrapping the Ribbon .................................................................... 173Steering the navigation features ...................................................... 174Confi guring with Settings windows ................................................. 176Viewing gallery windows .................................................................. 176Developing in Editor windows ......................................................... 177Introducing other helpful features .................................................. 179

Taking SharePoint Development Beyond the Browser ........................... 184Developing pages ............................................................................... 184Developing views for lists ................................................................. 188Styling your page with CSS ............................................................... 189Customizing a SharePoint workfl ow ................................................ 194

Chapter 9: Developing Reports with Report Builder . . . . . . . . . . . . . .199

Understanding Reporting Services ............................................................ 200Touring Reporting Services and its reports ................................... 200Managing the contents of reports ................................................... 202Setting up a library for reports ........................................................ 202

Taking a Spin around Report Builder ........................................................ 205Developing a Report .................................................................................... 208

Scrounging up some data ................................................................. 208Building a report ................................................................................ 212

Displaying a report in SharePoint ............................................................. 219

Chapter 10: PerformancePoint Development with Dashboard Designer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .221

Zooming in on PerformancePoint Services .............................................. 222Creating a Business Intelligence Center site .................................. 224Adding PerformancePoint content to a site ................................... 225

Taking a Spin around Dashboard Designer .............................................. 227Developing a Dashboard ............................................................................. 230

Launching Dashboard Designer ....................................................... 230Show me the data............................................................................... 232Understanding dashboard items ..................................................... 234

02_9780470888681-ftoc.indd xiv02_9780470888681-ftoc.indd xiv 1/27/11 5:50 PM1/27/11 5:50 PM

Page 17: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

xv Table of Contents

Part IV: Unleashing the Programmer Within ............... 247

Chapter 11: SharePoint Development with Visual Studio . . . . . . . . .249

Introducing Visual Studio ........................................................................... 250Getting into an Integrated Development Environment (IDE) ....... 250Telling the Visual Studio editions apart .......................................... 251

Examining the .NET Framework ................................................................ 251Installing the SharePoint Tools .................................................................. 253Taking a Spin around Visual Studio .......................................................... 254

Checking out SharePoint projects in Visual Studio ....................... 256Peering into SharePoint .................................................................... 259

Organizing Your Visual Studio Solutions .................................................. 259Adding projects to solutions ............................................................ 259Bundling projects into features ....................................................... 260Packaging fi les into a Web Solution Package ................................. 261

Discover the SharePoint Software Development Kit ............................... 262Using the SharePoint Developer Dashboard ............................................ 262Playing Nicely in Your Sandbox ................................................................. 263

Chapter 12: Commanding SharePoint through Code . . . . . . . . . . . . . .265

Understanding SharePoint Programming ................................................. 266Introducing Object-Oriented Programming ............................................. 267Discovering the SharePoint Object Model ............................................... 267

Distinguishing server OM from client OM ...................................... 268Listing your lists................................................................................. 269

Making SharePoint Accessible with Web Services .................................. 279Show me the services ........................................................................ 279REST-based Web Services ................................................................. 283

Lighting Up Your Site with Silverlight ....................................................... 285Understanding the need for Silverlight ........................................... 285Exploring Silverlight development .................................................. 286

Enhancing Your Portal with JavaScript .................................................... 288

Chapter 13: Developing Web Par ts . . . . . . . . . . . . . . . . . . . . . . . . . . . . .291

Understanding Web Parts ........................................................................... 291Discovering How SharePoint Uses Web Parts ......................................... 292Visualizing Your Web Part .......................................................................... 293Building a Visual Web Part ......................................................................... 294Creating Features, Packages, and Solutions ............................................. 299

Exploring Feature Designer .............................................................. 300Wrapping your work in Package Designer ...................................... 302

Moving Your Hard Work to SharePoint .................................................... 305Installing a package ........................................................................... 305Deploying a solution .......................................................................... 306

02_9780470888681-ftoc.indd xv02_9780470888681-ftoc.indd xv 1/27/11 5:50 PM1/27/11 5:50 PM

Page 18: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

SharePoint 2010 Development For Dummies xviChapter 14: Working from the PowerShell Command Line . . . . . . . .309

Getting Your Head around PowerShell ..................................................... 310PowerShell and SharePoint ........................................................................ 311

Entering cmdlets into PowerShell.................................................... 312Putting SharePoint cmdlets to work ................................................ 312Finding SharePoint cmdlets .............................................................. 314Asking PowerShell for cmdlet help .................................................. 315

Moving Beyond Simple cmdlets ................................................................ 316Saving a value with variables ........................................................... 316Looping ............................................................................................... 318Adding logic ........................................................................................ 320Working with PowerShell functions ................................................ 322

Writing PowerShell Scripts ......................................................................... 324

Part V: The Part of Tens ............................................ 327

Chapter 15: Top Ten Tools for SharePoint Development . . . . . . . . . .329

Web Browser ................................................................................................ 329SharePoint Designer .................................................................................... 330Visual Studio ................................................................................................ 330Report Builder .............................................................................................. 331Dashboard Designer .................................................................................... 331Excel .............................................................................................................. 332Visio ............................................................................................................... 333Word .............................................................................................................. 333Developer Dashboard ................................................................................. 334SharePoint on Windows 7 ........................................................................... 336

Chapter 16: Ten Places to Go for SharePoint Development Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .339

SharePoint Developer Center ..................................................................... 339Offi ce Developer Center .............................................................................. 340Developing Applications Guide ................................................................. 340Channel 9 Developer Course ...................................................................... 341Software Development Kit .......................................................................... 341SharePoint 2010 Guides .............................................................................. 341

Planning Guide ................................................................................... 341Deployment Guide ............................................................................. 342Setting up a SharePoint development environment ...................... 342

Deployment Planning Services .................................................................. 343Microsoft Hosted Information .................................................................... 343SharePoint 2010 Developer Training Kit ................................................... 343Magazines and Blogs ................................................................................... 344

02_9780470888681-ftoc.indd xvi02_9780470888681-ftoc.indd xvi 1/27/11 5:51 PM1/27/11 5:51 PM

Page 19: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

xvii Table of Contents

Chapter 17: Ten Ways to Reduce Business Costs through SharePoint Development . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .345

Organize Digital Content ............................................................................. 347Collaborate across a Portal ........................................................................ 348Consolidate Reports .................................................................................... 349Reap the Benefi ts of Analytics ................................................................... 350Centralize Company Information ............................................................... 351Store Product Documentation ................................................................... 352Streamline Customer Data Maintenance .................................................. 353Help Employees Help Themselves ............................................................ 354Allow for Personal Portal Space ................................................................ 354Move Infrastructure to the Cloud .............................................................. 355

Glossar y of SharePoint Development Terms ................. 357

Index ....................................................................... 365

02_9780470888681-ftoc.indd xvii02_9780470888681-ftoc.indd xvii 1/27/11 5:51 PM1/27/11 5:51 PM

Page 20: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

SharePoint 2010 Development For Dummies xviii

02_9780470888681-ftoc.indd xviii02_9780470888681-ftoc.indd xviii 1/27/11 5:51 PM1/27/11 5:51 PM

Page 21: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Introduction

Any fool can make things bigger and more complex. It takes a touch of genius – and a lot of courage – to move in the opposite direction.

— Albert Einstein

In the last few years SharePoint has taken the world by storm. In fact, the product is one of the fastest growing products in the history of

Microsoft. Companies of all sizes are rapidly implementing SharePoint and moving it to the center of their organization. The interesting thing about SharePoint, however, is that if you ask ten different people what it is, they will probably give you ten different answers. The reason is because SharePoint has become a platform with many different capabilities. Sure, it has document management — but it also includes features that span every-thing from business intelligence to electronic form management. With so much functionality, used in so many different ways, no wonder people think of so many different things when they think of SharePoint.

Having been a consultant for more than a decade, I can attest to the fact that every organization is different. The differences in organizations span every-thing from culture nuances to product-development cycles and everything in between. As a result, every organization implements and uses SharePoint in a way that makes sense within its own walls. Implementing SharePoint would be much easier if every organization could be shoehorned into the same little box. But every organization different — so too is the way every organization adopts SharePoint. To make matters worse SharePoint is dynamic. The needs of an organization are constantly shifting; the way SharePoint is used shifts as well. At first, you might want to use SharePoint as a portal to the company intranet (or, for that matter, to the Internet) and to manage your electronic content. As the portal is adopted, however, you might decide that you need to adopt a business-intelligence strategy. After you put your BI strategy is in place, integrating your backend Enterprise Resource Planning (ERP) system with SharePoint might become a priority as well.

If working with SharePoint were as simple as installing the product and watching it solve problems, then consultants like me would be out of a job. SharePoint is an extensive platform and requires development at nearly every junction. The good news is that SharePoint redefines the term “developer.” A SharePoint developer is no longer only the computer science guru who spends time sorting through bits and bytes, looking at line after line of com-puter code in hopes of enlightenment (or “optimizing a complex algorithm,” if you will). The SharePoint platform is designed with the end user in mind — and provides tools that anyone can use to develop a SharePoint solution.

03_9780470888681-intro.indd 103_9780470888681-intro.indd 1 1/27/11 5:51 PM1/27/11 5:51 PM

Page 22: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

2 SharePoint 2010 Development For Dummies

About This BookThis book is about understanding how to develop solutions on the SharePoint platform, and have the result come out rich with features and functionality. Using all that SharePoint has to offer is vital, Grasshopper, if you would bend the platform to your particular needs. By no means, how-ever, do you need a degree in computer science (or even an understanding of computer code) to develop for SharePoint. Everyday users, rejoice: If you’ve worked with Microsoft Office or Excel, then you can develop a SharePoint solution.

The tools vary but they all have one thing in common: You use them to extend SharePoint capabilities in ways that give you a solution that fits your needs. This book looks at the tools that are required — and how to use them.

How to Use This BookOkay, this book won’t replace your favorite beach reading (unless, of course, the SharePoint bug bites really hard). No need to read the whole book through from front to back — although, if you do, you’ll emerge with a holis-tic knowledge of SharePoint development. If you need to come up to speed on a particular tool (like, yesterday), then you can jump to that chapter prior to reading every chapter that precedes it. Get what you need first.

That said, this book does assume at least minimal SharePoint knowledge. If you are brand new to SharePoint, I’d recommend SharePoint 2010 For Dummies by Vanessa L. Williams as a quick way to get up to speed on basic SharePoint features and concepts.

How This Book Is OrganizedThis book is divvied up into five parts, beginning with an introduction to the different versions of SharePoint — and what kind of impact the version you have has on your development work. Other parts introduce you to the basics of SharePoint development, as well as best practices for using the primary development tools built in to SharePoint 2010. Read on for details.

03_9780470888681-intro.indd 203_9780470888681-intro.indd 2 1/27/11 5:51 PM1/27/11 5:51 PM

Page 23: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

3 Introduction

Part I: Understanding the SharePoint Development PlatformThis part gives a high-level overview of what SharePoint is all about — and the main features and components you can use to add value for business users. Chapter 1 provides a brief introduction to SharePoint. Chapter 2 discusses SharePoint Online, Microsoft’s hosted-solution offering that hangs out in the Internet “cloud”. Chapter 3 then walks you through an overview of SharePoint development and previews the topics covered throughout the book.

Part II: Developing with Your Web Browser and Microsoft OfficeIt’s amazing how much SharePoint development you can do without ever leaving your Web browser. SharePoint is a Web application — meant to be used with a Web browser such as Internet Explorer or Firefox. So the chapters in this part show you how that works: Chapter 4 discusses using your browser to develop SharePoint solutions. Chapter 5 discusses Excel in SharePoint, in its superpowered guise as Excel Services. Chapter 6 walks you through forms development with InfoPath Form Services. Finally, Chapter 7 discusses developing solutions that use Microsoft Word and Visio.

Part III: Exploring Standalone SharePoint Development ToolsPart III of the book discusses standalone tools that you use to develop SharePoint solutions. Chapter 8 discusses using SharePoint Designer to develop everything from sites and pages to content types and workflows. Chapter 9 covers Report Builder, which you can use to create reports that take advantage of SQL Server Reporting Services (SSRS). Finally, PerformancePoint development is the order of the day in Chapter 10, where you see how to use Dashboard Designer to build dashboards and other con-tent friendly to business intelligence.

03_9780470888681-intro.indd 303_9780470888681-intro.indd 3 1/27/11 5:51 PM1/27/11 5:51 PM

Page 24: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

4 SharePoint 2010 Development For Dummies

Part IV: Unleashing the Programmer WithinThis part dives into programming code by exploring Visual Studio as it relates to SharePoint (Chapter 11) and the SharePoint object model (Chapter 12). Chapter 13 walks you through developing Web Parts — a fundamental idea behind SharePoint. Finally, Chapter 14 explores developing PowerShell scripts for SharePoint, grappling with code fearlessly at the command line.

Part V: The Part of TensThe Part of Tens provides a quick reference to three topics to keep in mind as you start developing SharePoint solutions. Chapter 15 provides a top-ten list of SharePoint development tools. Chapter 16 lists ten places to learn more about SharePoint development. And Chapter 17 walks you through some of the best ways to reduce your business costs by using a solution that you (the mighty SharePoint user) develop.

Icons Used In This BookThe familiar For Dummies icons offer visual clues about the material con-tained within this book. Look for the following icons throughout the chapters:

Whenever you see a Tip icon, take note. I use it whenever I want you to pay particular attention to a point gleaned from my years of developing SharePoint solutions; the idea here is to shed some focused light on your SharePoint development efforts.

Whenever you see a Remember icon, get out your notebook and (ahem) take note — because chances are good that you’ll see these topics crop up again in your development efforts.

Okay, a consulting career has its roadblocks, no less than any other. It often takes hours to figure something out the first time — and then (fortunately) only minutes the next time you encounter the same problem. Often the root cause of your problem is a bug or some quirky behavior. I have tried to ferret out those little pitfalls so they won’t trip you up. Take note and beware.

When a particular development task or technique crosses paths with some heavy-duty technical knowledge (okay, some do), I call it out using the Technical Stuff icon. But relax. You don’t have to slave over every technical detail. The information is here if you decide you want to dig farther.

03_9780470888681-intro.indd 403_9780470888681-intro.indd 4 1/27/11 5:51 PM1/27/11 5:51 PM

Page 25: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Part I

Understanding the SharePoint

Development Platform

04_9780470888681-pp01.indd 504_9780470888681-pp01.indd 5 1/27/11 5:52 PM1/27/11 5:52 PM

Page 26: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

In this part . . .

In this part you get a bird’s-eye-view introduction to SharePoint as a development platform — that is, a look

at what SharePoint is and how it works as a fundamental part of developing business solutions (custom-tailored deployments of SharePoint capabilities). Traditionally, SharePoint is implemented on-site in an organization’s data center — but as software moves to “the cloud’ (that is, becomes one of many services delivered over the Web), new opportunities open up. Here you explore how Microsoft has turned SharePoint into a collection of ser-vices that live in the cloud. Not to worry; shifting some of the management and infrastructure-maintenance head-aches to Microsoft can free you to focus your efforts on what matters most — your business. The part wraps up with a high-level overview of SharePoint development to show how some of the tools you’ll be using use fit together in the bigger picture.

04_9780470888681-pp01.indd 604_9780470888681-pp01.indd 6 1/27/11 5:52 PM1/27/11 5:52 PM

Page 27: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

Chapter 1

Understanding the SharePoint Hype

In This Chapter▶ Understanding what the big deal is about SharePoint

▶ Exploring the benefits of SharePoint development

▶ Discovering the pieces that go into the SharePoint stack

I had one simple idea about telling friends about arts and technology events. People in the community suggested everything else to us, and that’s our theme. We’re really run by the people who use the site. We just run the infrastructure, and help out with problems.

— Craig Newmark (founder, Craigslist.org)

Even though SharePoint implementations are way more common now than they used to be, I’m constantly amazed at how many nontechnical

folks have heard about or used SharePoint. As a consultant and author, I’m constantly meeting new people from different walks of life. When the con-versation gets around to what it is we do for a living — and I mention that I am a SharePoint consultant — the typical response is usually along the lines of, “Oh SharePoint! We use that at my work.” Or “Oh yes, I use SharePoint at work. Can you help me with this thing it’s been doing?” Or “I have heard of SharePoint. A friend of mine uses it.” On the one hand, it’s reassuring to know that SharePoint is so pervasive that even people who are as far as pos-sible from a techie mindset still use it in some fashion. On the other hand, I’m always amazed about what people think SharePoint is. I’ve heard it described as a Web site, a way to send documents, and almost everything else high-tech (except maybe a death ray).

In this chapter, I give a brief history of SharePoint and explain exactly what all the hype is about. Because SharePoint is as much a development platform as it is a software product with many different pieces, I stitch those pieces

05_9780470888681-ch01.indd 705_9780470888681-ch01.indd 7 1/27/11 5:53 PM1/27/11 5:53 PM

Page 28: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

8 Part I: Understanding the SharePoint Development Platform

together for you so you’re armed with a big-picture view of what to expect as you begin developing SharePoint solutions. Finally, I introduce SharePoint development to you and fill you in on a secret that SharePoint developers would rather not discuss: You don’t have to be a programmer to develop solutions on the SharePoint platform. If you can use a Web browser, then you can develop a SharePoint solution. If you’re ready to add “SharePoint Developer” to your résumé, all you have to do to get started is read on.

Everyone Can Be a SharePoint DeveloperWhen most people think of a “developer,” they think of a computer-science geek sitting in a basement with a can of Mountain Dew banging out complex computer code. In the past, this was often not far wrong; getting a computer to do something specific to solve your problem required writing a com-puter application using special programming languages that would then be compiled down into the 1s and 0s that a computer could understand. These languages were, and still are, complex and mysterious and require an extraor-dinary amount of dedication and knowledge.

If you’re a hard-core programmer, no sweat — your skills will always be useful. Until computers take on thoughts of their own, we need program-mers just as we need surgeons for our (very human) bodies. The good news, however, is that software applications are evolving in a very real and exciting way. Tools are becoming available that give users and analysts outside the IT department more effective ways to command their computers to create solu-tions to real-world business problems. That’s where SharePoint comes in.

SharePoint 2010 provides a number of tools and features designed to shift more of the development power away from programmers and into the hands of the people who understand their particular business problems best. By and large, these are businesspeople who could care less about technology and are just trying to do their jobs. The SharePoint development tools allow users to create no-code solutions in a self-serve manner; no need to interact with IT. This takes some of the time burden off of the IT department so it can focus on (say) creating stable, redundant, always-available, and secure computing environments. Everybody wins — at least that’s the idea.

As a technology consultant, I’m constantly filling the role of intermediary between the business users and the technology people. I’m very excited to see this quiet change in development responsibilities. Because the SharePoint 2010 platform and tools for developing business solutions are designed with the end users in mind, a new level of business efficiency and productivity becomes available.

05_9780470888681-ch01.indd 805_9780470888681-ch01.indd 8 1/27/11 5:53 PM1/27/11 5:53 PM

Page 29: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

9 Chapter 1: Understanding the SharePoint Hype

Tracing the Origins of SharePointComputers created an information revolution that fully blossomed as they started to get connected together into large networks. The biggest network of all, the Internet — and the fact that computers became cheap enough to sit on nearly every desk at home and work — created a recipe for sharing infor-mation. To fulfill this need, technology such as e-mail and the World Wide Web cropped up in the 1990s. Soon Web sites flourished, nearly everyone had an e-mail address, and information flowed freely. Throughout the 2000s organizations rapidly adopted corporate e-mail systems in order to facilitate communication.

In addition to e-mail, organizations also adopted large enterprise computer systems that handled everything from inventory to human resources. These systems are known as Enterprise Resource Planning (ERP) — with some of the biggest players being SAP, Oracle, Microsoft, and Sage. As companies adopted ERP systems in the ’90s, others followed suit to stay competitive. As we head into the 2010s, the next wave of efficiency and productivity for knowledge-based workers will come from communication, collaboration, and centralized information sharing.

As SharePoint has come of age, it’s put more tentacles into the Microsoft Office applications — resulting in a centralized, integrated portal platform that’s controllable from familiar applications — so the race to implement SharePoint continues. Various companies offer software products for cre-ating and using a company portal space — but so far the clear winner is SharePoint.

So What Exactly Is SharePoint, Anyway?Microsoft highlights these defining characteristics of SharePoint:

✓ SharePoint Server is a suite of integrated server capabilities. In essence, if you install SharePoint on your server, you give it a new range of information-wrangling powers that work together.

✓ SharePoint manages content (your business information) and provides enterprise-wide search capabilities. Wherever the needed information is in your organization, SharePoint can find it, make it usable, and keep it secure.

✓ SharePoint, when used to full advantage, accelerates business processes that require collaboration by making communication easier (and infor-mation easier to share) across departmental boundaries.

05_9780470888681-ch01.indd 905_9780470888681-ch01.indd 9 1/27/11 5:53 PM1/27/11 5:53 PM

Page 30: SharePoint › download › 0000 › 5889 › 17 › L... · 2013-07-23 · SharePoint is a platform with many different pieces that help you accomplish things with your data. This

10 Part I: Understanding the SharePoint Development Platform

✓ SharePoint can help improve the administration of your company server, extend existing software applications with server-based capa-bilities, and help a wide range of software and hardware play well (and work well) together.

These points are great and tell you what SharePoint can do, but they don’t really tell you what it is. If you’re like me, you’re looking for an explanation that has some roots. Something concrete. Is SharePoint a software program or a standalone supercomputer? Is SharePoint something that runs on my local computer like Microsoft Office or does it live somewhere in a data center?

To get a handle on SharePoint, start from the bottom and work up through its components — which you can see in Figure 1-1. The following sections explain each part of Figure 1-1 in more detail.

Figure 1-1: The

components that make

up a SharePoint

environment.

Starting with the roots — computer hardwareEvery computer system starts with physical components — central pro-cessing unit (CPU), memory, a hard drive, power supply, and motherboard. Typically a computer comes into your workplace in one of two ways: You can buy all the individual pieces and put them together yourself or you can

05_9780470888681-ch01.indd 1005_9780470888681-ch01.indd 10 1/27/11 5:53 PM1/27/11 5:53 PM