Discover millions of ebooks, audiobooks, and so much more with a free trial

From $11.99/month after trial. Cancel anytime.

Professional SharePoint 2010 Development
Professional SharePoint 2010 Development
Professional SharePoint 2010 Development
Ebook1,501 pages13 hours

Professional SharePoint 2010 Development

Rating: 0 out of 5 stars

()

Read preview

About this ebook

Updated guidance on how to take advantage of the newest features of SharePoint programmability

More than simply a portal, SharePoint is Microsoft's popular content management solution for building intranets and websites or hosting wikis and blogs. Offering broad coverage on all aspects of development for the SharePoint platform, this comprehensive book shows you exactly what SharePoint does, how to build solutions, and what features are accessible within SharePoint.

Written by a team of SharePoint experts, this new edition offers an extensive selection of field-tested best practices that shows you how to leverage the vast power of this multi-faceted tool to build custom workflow and content management applications. Plus, you'll discover how to take advantage of the new features to roll out new SharePoint sites or upgrade existing sites.

  • Keeps you thoroughly up to date on all the most recent changes to SharePoint 2010
  • Reveals broad and deep coverage of social media features, content management applications, enterprise search, business connectivity services, user experience development, and custom workflow
  • Examines SharePoint Server 2010 vs. SharePoint Foundation Server
  • Highlights ways you can take advantage of improvements to offline and mobile client capabilities, improvements to SQL Server table support, Cloud-based offerings with Azure integration, social networking additions, and more

Professional SharePoint 2010 Development, Second Edition presents you with authoritative coverage on all aspects of development for the SharePoint platform.

LanguageEnglish
PublisherWiley
Release dateMar 6, 2012
ISBN9781118238684
Professional SharePoint 2010 Development

Related to Professional SharePoint 2010 Development

Related ebooks

Software Development & Engineering For You

View More

Related articles

Reviews for Professional SharePoint 2010 Development

Rating: 0 out of 5 stars
0 ratings

0 ratings0 reviews

What did you think?

Tap to rate

Review must be at least 10 words

    Book preview

    Professional SharePoint 2010 Development - Thomas Rizzo

    Chapter 1

    Introduction to SharePoint 2010

    WHAT’S IN THIS CHAPTER?

    Information about tools to integrate with Silverlight, LINQ, and BCS

    New features in social computing

    New features in ECM

    New features in Search

    New features in SharePoint Workspace

    New Features in SharePoint Online

    Microsoft SharePoint Server 2010 introduces a lot of new functionality that you need to understand to write better applications on the platform. Beyond increasing the new features in each of the SharePoint workloads, such as collaboration or portal, Microsoft has added entirely new products to the SharePoint family, including the acquired FAST technologies for Enterprise Search and the PerformancePoint services that enhance SharePoint’s business intelligence (BI) capabilities. With these new additions, the surface area of SharePoint has doubled, so this chapter quickly introduces the new sets of features in SharePoint and the Office client.

    WHAT’S NEW IN THE SHAREPOINT PLATFORM AND TOOLS

    SharePoint, as a development platform, has matured over time from server APIs to web services to now supporting the latest developer technologies, such as Silverlight, Language Integrated Query (LINQ), and REST APIs. Developers who build on the SharePoint platform will find some very welcome additions to the platform, which users have been requesting for a number of years, such as the ability to develop and test on client operating systems, including Windows Vista and Windows 7. You no longer need to do remote development or run a virtual server OS on your client machine to develop on SharePoint. The next sections look at the top new enhancements in the platform that you can build against.

    Language Integrated Query

    In the 2008 release of Visual Studio and .NET 3.5, Microsoft introduced new technology and semantics that allow developers to write against objects that map back to a number of different datasources, even if those datasources don’t store the data using object storage. Effectively, LINQ is an object mapper with special operators in the .NET languages. Therefore, you can take a relational database table, use Visual Studio to map the database to your objects, and then write to your objects. For LINQ to work, you need a provider that takes the object calls and translates them into the correct native calls of the underlying datasource, such as SQL queries for databases. With SharePoint 2010, a new LINQ provider for SharePoint converts object operations into the correct SharePoint operations using the native Collaborative Application Markup Language (CAML) language that SharePoint understands.

    List Enhancements

    Lists are a critical part of the SharePoint platform. In fact, everything in SharePoint is powered by lists, whether it’s a built-in application or your own custom application. With the 2010 release, lists have new, long-awaited functionality, including new scale limits, XSLT views for better customization, list relationships that allow cascade deletes and updates to work, and formula validation for columns in a list. There is also a new list type called the External Data List. This type of list allows you to display external data, such as database or web service data, inside SharePoint with read/write capabilities. You’ll learn more about this new type of list later in the book in Chapter 4.

    Business Connectivity Services

    Business Connectivity Services (BCS) is the new name of the Business Data Catalog technologies from SharePoint 2007. BCS is greatly enhanced in the 2010 release with read/write capabilities, support for Windows Communication Foundation (WCF), and new client capabilities so that you have APIs on the server and the client, and can sync line-of-business (LOB) data from your backend systems to the client cache and work on that LOB data when offline. BCS synchronizes the data from the client with the server when you reconnect. As part of the tooling, SharePoint Designer and Visual Studio include entity-modeling tools for BCS so that you can create business objects that connect to your LOB datasources from within these tools, and write your business logic for reading and writing your LOB data.

    Silverlight Integration

    If you are using SharePoint 2007, one of the biggest challenges is trying to get Silverlight to work in a SharePoint environment. You have to modify your web.config, hack around to deploy your Silverlight application to a content viewer web part, and then hope you don’t need to debug the application. Silverlight shipped after SharePoint 2007, which made it difficult for the SharePoint team to foresee the requirements of being a great Silverlight host. With the 2010 release, SharePoint has become that great Silverlight host. Built into SharePoint is a Silverlight web part; you can drag and drop this web part onto your page, point it to your Silverlight application, and start using the Silverlight application in your SharePoint environment in minutes.

    Client-Side OM

    Frequently, developers want to write applications that need to talk to SharePoint from a client operating system and from client applications, such as the ones in the Office suite. With the addition of Silverlight integration to SharePoint, a client object model is critical because it makes it easier for developers to write applications against a full object model, rather than trying to call web services from within their client applications. Additionally, because Silverlight runs on the client rather than running server-side, the client object model (OM) makes it easier for developers to build rich Silverlight applications on SharePoint. SharePoint 2007 requires you to write against untyped web services for remoting your applications. The client object model provides a more productive development experience since it provides a typesafe environment that works with the IntelliSense in Visual Studio.

    In addition, the client OM comes in other flavors such as a JavaScript version of the OM. This version allows you to write applications in JavaScript that talk to SharePoint. You can then use additional JavaScript libraries such as jQuery to format the results of your client code. In addition, with the forthcoming HTML5 standard, you’ll be able to combine all the client-side technologies SharePoint supports with HTML5 to build next-generation SharePoint applications.

    Web 2.0 Protocols and New Standards

    There are a number of new protocols and standards that SharePoint 2010 implements across its workloads. Some are considered Web 2.0 protocols, such as Representational State Transfer (REST), Asynchronous JavaScript + XML (Ajax), JavaScript Object Notation (JSON), and ATOMSub/Pub, whereas others are going through standards validation, such as the Content Management Interoperability Services (CMIS). SharePoint still continues to support other standards such as WebDAV and web services. The addition of these newer protocols and standards allows SharePoint to interoperate with other systems more easily, whether to create mash-ups between systems hosted in SharePoint or to allow data interoperability between systems.

    Sandbox Solutions and Resource Governors

    One of the biggest downsides to developing custom solutions in SharePoint 2007 is the requirement for the solution developer to be an administrator on the server. Often, IT administrators won’t allow developers to access the server with the elevated privileges they need to deploy their solution, as custom web parts or other SharePoint solutions require that you place your code in the global assembly cache (GAC) or in the filesystem related to your SharePoint site. Plus, the administrator has no simple way to ensure that badly written code does not slow down the system, crash it, or perform malicious activities. You could implement code access security (CAS), but that requires you to write the code to implement it; in addition, managing CAS policies is not a simple task.

    However, with SharePoint 2010, there is a new feature called Sandbox Solutions that allows for the deployment of SharePoint solutions inside a secure environment hosted in SharePoint. Because it is a secure environment, the IT administrator can control who can deploy solutions and how many resources these solutions receive through the new resource governors built into the system. For example, if a custom-developed solution is using too many CPU resources, SharePoint will automatically stop running the solution. That said, today the Sandbox Solution offers only a subset of the SharePoint object model, so although it might be a good solution for some custom applications, you have to evaluate whether there is enough functionality to meet your application needs.

    SharePoint Designer

    Besides making SharePoint Designer (SPD) free, Microsoft has invested in making SharePoint Designer better in the 2010 release. SPD has been redesigned to have more of a SharePoint-based view than the folder-based view it previously had. Now, you can browse by the types of items you are looking for rather than just through the site hierarchy. In addition, SPD introduces a new entity modeler to make it easier for you to build BCS connections to your backend systems and model the backend data inside of the SharePoint entity system. Finally, SPD has enhanced the workflow design capabilities that import Visio diagrams into SPD and allow you to add business logic to those diagrams using the SPD Workflow Designer, and then display the graphical status of your workflow overlaid on those diagrams as part of your workflow.

    SPD 2010 will continue to be a free product, which makes it an invaluable additional tool for any SharePoint developer, even if you just use it as a simple web design or SharePoint debugging tool.

    Visio and Access Services

    Two new web companions are available in SharePoint 2010 — Visio Services and Access Services, in addition to the previous web companions — Excel Services and InfoPath Form Services. With Visio Services, you can design your Visio diagrams, connect those diagrams to backend systems for visualization of data, and then post those diagrams to SharePoint. SharePoint renders your diagram, with the data connectivity, through the SharePoint web experience.

    Please note that the Visio web rendering is read-only, and to get the Visio Services functionality, you need a high-end version of Visio called Visio Ultimate. (Incidentally, this product is not part of the Office Ultimate suite.)

    With Access Services, you can convert your Access applications to web-based applications. With the previous version of Access, Access 2007, you could take certain Access databases that were compatible with SharePoint’s logical data model and export that data to SharePoint but still manipulate it from within Access. With the new capabilities that Access Services provides, you can take your Access forms and move them over to web-based forms to complete the transformation of your application.

    InfoPath (Forms, List Forms, Mobile Forms)

    InfoPath Form Services has a number of new enhancements, including the ability to replace list item forms for activities such as editing properties on an item. This makes it easier to build richer forms with business logic and data connectivity that work in the rich client through the new SharePoint Workspace (formerly Groove), which is covered later in this chapter, and in the browser. In addition, InfoPath Forms Services adds new mobile form capabilities that enable you to create forms that run across mobile devices, browsers, and Office clients.

    Visual Studio

    With Visual Studio (VS) 2010, there is a major jump ahead for SharePoint developers. Previously, VS did not have much SharePoint development functionality and you had to download the community-supported Visual Studio Extensions for Windows SharePoint Services. With VS 2010, you can browse your SharePoint environment from the Server Explorer to quickly see your lists, libraries, content types, workflows, and other SharePoint artifacts. A visual Web Part Designer frees you from having to hand-code HTML to add visual elements to your web parts. An entity-modeling tool works with the BCS technologies that were discussed earlier so that you can model your business entities, write your business logic, and connect SharePoint to your backend systems. Finally, VS integrates SharePoint development into a team development environment with support for Team Foundation Server and easy deployment using the new Web Solution Package format, which is discussed next.

    Web Solution Packages

    To make it easier to package and deploy solutions, SharePoint 2010 improves the Web Solution Package (WSP) format so that it is supported across all tools, allowing you to export your site through the browser, SharePoint Designer, and Visual Studio. This means that you can quickly upgrade or downgrade your solutions between the tools, depending on the person working on the solution or the tool required to build the solution. In addition, SharePoint Online, the Microsoft-hosted version of SharePoint, supports this format so that you can move solutions from on-premises to the cloud without having to change formats or rework the package.

    Developer Dashboard

    One of most common culprits of poorly performing SharePoint sites is poorly functioning code, whether the problem is bad .NET code, bad database calls the .NET code makes, or coding errors that cause excessive CPU, disk, or memory utilization. Tracking down and determining where the issues are in the code was a laborious process in the 2007 release. SharePoint 2010 introduces a new developer dashboard that allows you to see all the calls made on a page right inside of the user interface. Those calls can be ones that SharePoint is making or they can be your custom code. By looking at the call stack, response times, and utilization, you can quickly uncover where your code is performing poorly and try to fix it.

    WHAT’S NEW IN COLLABORATION/SOCIAL COMPUTING

    Collaboration and social computing are two of the fastest changing technologies in the industry. Just a few years ago, a number of technologies in this space did not exist, such as social tagging, microblogging, and the APIs that support these technologies. SharePoint 2010 adds new capabilities in these areas, but these technologies aren’t done innovating, so at some point you may have to build your own social capabilities on top of SharePoint 2010 to take advantage of future technological advances.

    Enhanced Blogs and Wikis

    SharePoint 2007 introduced blog and wiki capabilities to the SharePoint product. The most interesting piece of the blog and wiki capability was the integration with the rest of the SharePoint functionality for versioning and content approval. Unfortunately, blogs and wikis were a late addition to the 2007 product, so not all of the desired functionality made it into the final release. In the 2010 product, blogs and wikis are enhanced to add new capabilities to the core blog and wiki functionality. Also, these applications can take better advantage of new 2010 capabilities, such as content rating, tagging, and feeds. In addition, records management can now be applied to blogs and wikis just like any other content in SharePoint so that you can have compliance and governance on your blog and wiki content. Finally, SharePoint introduces enterprise wikis, which combine the content publishing and social features to provide a more robust wiki solution that has capabilities such as ratings of wiki pages.

    Social Tagging and Ratings

    One phenomenon on the Internet is social tagging and content rating. If you have ever used Delicious or Digg, you’ve used a social tagging technology where you can search, sort, and filter by tag, track what other people are tagging, and obtain feeds on your tags related to your areas of interest. Combined with tagging, ratings help you understand the value of the content and can help filter out poor content based on other people’s ratings. Both of these features are implemented in the 2010 release so that you can tag anything in SharePoint, whether it’s content or people. Plus, you can rate all of your content, so if you want to find all Word documents rated with four or more stars, you can quickly search your site to find this information. There is a blurring of the line between social and Enterprise Content Management (ECM) areas, as you will see throughout this book. The two areas are converging, with social being the bottom-up technology driven by users and ECM being the top-down technology that helps with compliance in your social environment. Many of the features are shared between the two technological areas, especially tagging, where the social tag infrastructure, called folksonomies, are actually open term sets in a corporate taxonomy. Finally, as everyone always asks about this in regard to 2007: yes, SharePoint 2010 does ship with a Tag Cloud web part.

    Activity Feeds

    If you have used Facebook or MySpace, you know how powerful it is to have the ability to track what your circle of friends is doing. In a corporate environment, understanding what is happening in your social network is important as well. For example, if someone is working on a document that you may be interested in and that information appears in your social feed, you can quickly view the document. Another example is if there is a tag that you have been tracking as an interest area; you may want to get an activity feed on that tag as people tag other content or people with it.

    Social Bookmarking

    Often, there are interesting web bookmarks that people want to share with other members of their organizations. These bookmarks can be internal or external websites and can be rated, tagged, or shared using the other social features included in SharePoint. You can think of Social Bookmarking as a special way to use tagging in SharePoint.

    Organization Browser

    In large and small organizations, browsing through an organizational chart is a good way to get an understanding of which people are in which groups and what they work on. Although SharePoint 2007 shipped a simple organizational tree view, many customers wanted something richer with which to look at their organizational hierarchy and the rich profile information stored in their organization. SharePoint 2010 ships with a Silverlight-based organizational browser. The advantages of using Silverlight are a better navigation experience and the ability to quickly navigate the organizational hierarchy without postbacks to the server.

    Outlook Social Newsfeeds and Expertise

    No social solution would be complete without integrating into the most popular information management client that people leave open on their desktop all day — Outlook. While Outlook and SharePoint integrate today for working with tasks, discussions, and documents, Outlook 2010 now integrates with SharePoint and other social technologies, such as Facebook or MySpace, through its ability to expose richer information about people such as pictures, activity feeds, previous conversations, and even previous instant messaging sessions. By showing related information, you can quickly grasp the conversation semantics and ascertain the people involved.

    Beyond social newsfeeds, Outlook supports expertise mining by discovering, displaying, and allowing you to approve keywords associated with you based on your email communications. These keywords are stored with your profile, so they are searchable, which makes connecting to experts in an organization easier.

    Mobile Client

    The mobile client supports browsing your SharePoint sites, synchronizing the content offline to your mobile device, and performing searches. By having a mobile client, you can quickly find information about people, including their status updates, tags, expertise, and other social information.

    Social Search

    Once you start using the new social features of SharePoint, finding information becomes easier because of the ability of the search engine to leverage the social information contained in other pieces of the product. Tags work with search queries, content rating can be used to refine results, and you get better social distance calculations and expertise results because of the enhanced people profiles. An improved Search user interface makes finding the right information easier with a preview of Office documents, expertise location, and better navigators for filtering down to the right content or person.

    WHAT’S NEW IN SEARCH

    With the acquisition of FAST, Microsoft is making a lot of changes in Search from the low end to the high end. With these changes come new challenges for the developer trying to understand which technologies to use and how to write custom code. These developments also present new opportunities to innovate in the applications you create that are powered by Search.

    New Core Search Query Capabilities

    One criticism of the 2007 release was that Search did not support wildcards, suffix matchings, grouping of query terms, or logical operators. Many of these deficiencies were not the result of the engine not supporting these options; it was that the search web parts did not expose these capabilities. So, developers had to write custom user interfaces to the search API if they wanted this functionality, which meant recreating all the functionality shipped in the web parts. With 2010, you no longer need to write this functionality yourself. In fact, the search web parts are also extensible in this release, unlike in 2007, in which they were sealed from developers.

    Enhanced Core Search Results

    There are a number of new capabilities in the visualization of search results. If you have seen search results for people in 2007, you will be familiar with navigators that allow you to refine your results based on different properties, such as a person’s title or department. This capability has been expanded to support not just people results but also core content results so that when you run a search, you can filter by author, document type, and other properties.

    Beyond the navigators, Search provides rich previewing of content by leveraging the integrated FAST technologies. When an Office document is the search result, end users can preview that document. They do not have to open the document to determine whether it is the result they wanted. Instead, they can just preview the document, and then open it if they want to, which saves time hunting and pecking for the right content.

    Enhanced People Search: Phonetics

    Often when people are searching for another person, they don’t know how to spell certain parts of the other person’s name. They may know how it sounds phonetically but not know the exact spelling. Normally, with Search, if you don’t spell the name correctly, the engine can’t find it. However, with the 2010 release, the query engine has a phonetic search capability for searching for people. As long as the spelling sounds like the name of the person (such as searching for Tom Risso when you are in fact looking for Tom Rizzo), the engine will sound out the search term and find the right person.

    Enhanced People Search: Address Book–Style Lookups

    Most people are guilty of using the Outlook Address Book as a search engine or organizational browser. You need to find someone, so you fire up a new message, type her name, and try to resolve it, or you open the address book and start typing. You may use the person’s alias as a shortcut to looking up her name. However, if you tried the same thing in SharePoint, using the partial names or putting in an alias, you would get different results or no results. With 2010, address book–style lookups are supported to allow you to type an alias for someone and quickly find the person you are looking for.

    Enhanced People Search Results

    In 2010, the people results page is enhanced to show you more information about people, especially their expertise and place in the organizational hierarchy. The search results show inline the expertise that the person has, which allows you to find the person who has the expert skills that you are looking for. In addition, there is a quick link to the organizational browser so that you can quickly surf the organization to understand the hierarchy and reporting structures.

    New Search Connector Framework

    Although SharePoint 2010 continues to support the protocol handler technologies for building search connectors to other systems, it ships with a new connector framework built on the business data connector. The BDC-style connectors are easier to write, can be written in managed code, and allow you to have a seamless experience from connecting the datasource to the end user, because the BCS is present throughout the product from search through surfacing in lists or content types.

    FAST Integration

    Microsoft has introduced a new piece of the SharePoint family: the FAST Search for SharePoint product. This new product brings the power of the acquired FAST technologies to the SharePoint environment, including integrated FAST web parts, an advanced indexing and query engine, and new search functionality. Some of the enhancements in FAST include more complex query support, entity extraction, sentiment analysis, and larger scale. With these new advanced capabilities, you can extend beyond what the SharePoint Search does out of the box and provide a seamless experience for your end users, while taking advantage of the new FAST capabilities. Chapter 6 gives you great depth on the new FAST functionality.

    WHAT’S NEW IN ENTERPRISE CONTENT MANAGEMENT

    SharePoint 2010 introduces a number of new Enterprise Content Management (ECM) features, such as taxonomy, better records management, and enhancements to existing ECM features such as document management. Using ECM in your SharePoint solutions continues to be the highest of all the workloads, so understanding what is offered both from a new features and platform standpoint for ECM is important as you write your SharePoint applications.

    Document Management

    Document management has been a core part of SharePoint since SharePoint 2001. SharePoint 2010 innovates with a number of new features that round out the product and provide new platform services for developers.

    Metadata Management and Navigation

    SharePoint 2007 provided hierarchical folder-based navigation, which is very similar to a file share navigation that you see in your Windows client or server infrastructure. Although folder-based navigation is a good way to organize and browse files, sometimes you want to navigate not by location but by metadata in your content. You may have used the stacking feature in Windows Vista, where you can stack by author, type, or other metadata to help you navigate large collections of files. SharePoint 2010 provides a similar feature, called metadata views. With metadata views, you can organize your navigation and also list views by using the metadata of your content. This way, even if the content is stored in a subfolder that’s 50 folders away from the current folder, as long as the metadata matches the requested metadata in the view, that content appears. The new taxonomy service, which you’ll learn about shortly, combined with metadata views, increases the power of SharePoint to store, manage, and visually represent your data.

    Location-Based Metadata

    Unfortunately, people do not always fill out metadata. They either feel it’s a burden or don’t understand what the metadata should be. Without metadata, it’s difficult for others to find the information and for SharePoint to crawl and index that data. SharePoint 2010 supports location-based metadata so that if a user posts a document into a specific location, metadata is automatically filled in for the user. Imagine that you have folders that are particular projects: a, b, and c. SharePoint can automatically fill in the metadata with the project name according to where users put content. Downstream, Search can crawl that metadata and you can navigate your search results by project name, or you can use the metadata as properties in the documents.

    Document Routing

    If you have ever seen the records-routing feature in SharePoint 2007, the document-routing feature will be familiar to you. Based on content types and a set of rules, documents now can be routed to their correct location across your SharePoint infrastructure. Imagine a scenario in which your end user doesn’t know where to save a particular file based on the corporate taxonomy. With document routing, the end user can submit it into SharePoint, and SharePoint routes the document to the right location.

    Unique Document IDs

    One big feature request for SharePoint 2007 that is now provided in 2010 is the ability to have unique document IDs so that users can search by document ID and quickly find the document that they were looking for. Plus, given the fragile nature of URL-based location, document IDs are a good replacement, because the ID never changes, even if a user moves a document. The ID can be used as metadata in the document, and lookups work with the search engine, so you can quickly find documents using IDs with Search.

    Taxonomy Services

    One of the big advancements in 2010 is the addition of a taxonomy service. The taxonomy allows you to define different taxonomy hierarchies and apply them to your content. For example, you can create a taxonomy for products or a taxonomy for customers. The taxonomy service is an enterprise-wide service, so it can be shared across site collections. Plus, it works both as a top-down corporate taxonomy with locked terms and as a bottom-up folksonomy, which allows users to add new terms to the taxonomy. The term sets supported by the taxonomy service also support synonyms, so you can allow related terms in your set. Finally, the Office client ships with controls that understand the term sets you create, so in Office you can quickly tag your content with the terms and use features like synonyms or autocomplete.

    Document Sets

    Often when you are working with content, your project is made up of more than one piece of content. For example, if you are writing a sales proposal for a customer, you may have a Word document for the proposal, a PowerPoint presentation that walks the customer through your proposal, and an Excel document that contains the financials of your proposal. Together, this content is your proposal. With SharePoint, you can put all of this content in a document library, but you still must maintain each piece of content separately because you can’t check out the set of content or perform a workflow on the entire set. This is solved by Document Sets in SharePoint 2010.

    With 2010’s new Document Sets feature, you can combine disparate content into a set and provide metadata, a user interface, a workflow, and document management on the individual content and the set. The easiest way to think about a document set is that it is just an enhanced folder type in SharePoint. With the set, you get a Welcome page that you can customize, metadata for the set and default metadata you can push into the content in the set, and even default content that can be created when the set is created. Document sets can be versioned independently of the versioning of the content in the set. Finally, you can export the set, and SharePoint zips together all the content in the set for you.

    Word Services

    One of the biggest feature requests for Microsoft Word has been a server-side, programmable version of the Word engine to allow applications to convert documents or perform document assembly. Because the Word object model is not supported in a server environment, the only other choice is to write to the OpenXML format so that you can hand-generate a document to meet your needs. However, OpenXML is XML, which is not the easiest thing to create from scratch given its verbose nature. With SharePoint 2010’s Word Services, you now have an API on the server that provides conversions and assembly without having to write to XML APIs. This is useful in many scenarios. For example, if you’re working for an insurance company and you need to generate the insurance policy for your clients, which involves pulling information from your backend systems, emailing the policies to your agents, printing them, and mailing them to the end customer, Word Services can perform these steps on the server for you, giving you fast throughput document creation but in a format that is human-readable and editable.

    CMIS Support

    Content Management Interoperability Services (CMIS) is a new standard that allows for the interoperability between content management systems. The standard is sponsored by Microsoft, IBM, Oracle, Alfresco, OpenText, and a number of the other vendors in the content management industry. From a technology standpoint, CMIS is not just a create, read, update, and delete (CRUD) interface to the different systems that support the standard. It provides higher-level semantics that work across all systems, such as check-in and check-out of the systems. The standard is built on other industry standards such as REST APIs for performing the operations against the different systems.

    Records Management

    Records management is a newer workload in SharePoint, introduced in SharePoint 2007. With 2010, this workload gets some much-needed features that make SharePoint 2010 a viable, enterprise-capable records-management solution.

    Multi-Stage Disposition

    Often in records management, you want to be able to have multiple stages in your dispositions of documents, such as different points where you review the content, or be able to set different dispositions based on different rules. For example, you may want to have a five-year destruction rule with a one-year review rule to double-check the content and perhaps a 10-year destruction rule if the document is digitally signed. With 2010, multistage dispositions allow you to set different rules for your managed content based on your business requirements.

    In-Place Records Management

    In SharePoint 2007, you need to send your managed content to the Records Center to get certain features of the product to work. However, you may want to use records management with your content but leave it in place in your document libraries and lock it from editing. With the new in-place records management in 2010, you can apply records-management policies to content, while retaining the content in its original location.

    Web Content Management

    Interest in building rich websites is growing every day. If you look at Internet and intranet sites, design, rich media, and social interaction are all important features. To provide these, you need a good base web content management platform on which to build these solutions. With SharePoint 2010, WCM gets much more than just a facelift, and combined with the other enhancements in SharePoint that WCM can leverage, such as social or search, SharePoint WCM becomes an enterprise-ready WCM solution.

    Standards and Browser Support

    To move away from the table layouts that cause issues in browsers other than Internet Explorer, SharePoint 2010 uses Cascading Style Sheets (CSS) and XHTML to provide layout information and strict HTML. In addition, to support accessibility, along with the changes to the HTML that SharePoint renders, SharePoint supports the Web Content Accessibility Guidelines (WCAG) accessibility standards. Finally, with the new rendering, support for non-IE browsers has been increased to fully support Firefox and Safari.

    One-Click Page Layout

    Many people have issues in SharePoint 2007 when trying to change their page layout after they create their page. With the 2010 release, creating and changing page layouts requires only a single click of the mouse. With this, you can quickly see how your content appears in different page layouts so that you can choose the best design for your site.

    Enhanced Page Libraries

    With 2010, you can have folders in your Pages library, which allows you to scale the number of items, to the millions, you can store there. SharePoint can automatically place the content into your subfolders using the content-routing engine discussed earlier. Not having folders in the Pages library was a major difficulty in the 2007 release.

    Social Computing Crossover Features

    With the convergence of ECM and collaboration/social areas, there are many crossover features that you can take advantage of on your intranet- or Internet-facing site that live in both worlds. For example, you can use the tagging and rating system built into SharePoint 2010 to build internal social communities or for external customer social communities. You can use social bookmarking internally or for external sites. The list goes on and on, but the key thing is that ECM and the social area are coming together, so the features you see in either area are applicable to the other, and they’re all built on the common SharePoint platform.

    Digital Asset Management

    If you are using SharePoint 2007, you probably have run into the limitations around SharePoint’s support for digital assets. Storing and streaming media from SharePoint 2007 is not efficient and SharePoint 2007 does not understand images or other rich media as deeply as you want. With 2010, much of this is remedied by the new support for digital asset management in the product.

    Digital Asset Content Types

    SharePoint 2010 supports content types out of the box for the most common digital assets, including video, audio, and images. As part of these content types, audio and video properties are supported, including data rates, frame height, width and rate, preview image URLs, and copyrights. By including a content type, you can leverage the rest of the SharePoint functionality to manage these types of data, including workflow and records management.

    Bit Rate Throttling with Internet Information Server

    To ensure that you stream the media out of the server, SharePoint 2010 supports bit rate throttling in Internet Information Server (IIS). The bit rate throttle reduces the bit rate of the media download to the correct speed based on the data rate of the source video. By doing this, media serving can scale better, and you get reduced cost for your bandwidth, because fewer users drop out after 20% of the video has played; you’ve throttled the usage rather than tried to deliver the entire video to the user at maximum speed. The easiest way to think about bit throttling is as just-in-time delivery of the content.

    Content Rating

    You will see many of the social computing features cross over into the ECM world, as there are requirements to manage social content just like any other digital content. With the Digital Asset Management (DAM) pieces of SharePoint, you can use content rating to rate the content so that only the highest-rated content is displayed or returned in search results.

    Remote BLOB Storage

    To support binary large object (BLOB) files, such as videos, SharePoint supports a remote BLOB storage provider model. This model requires drivers from your storage provider, and once configured, the provider allows you to move the BLOBs from SQL Server to the location that the provider supports. SharePoint maintains transactional consistency between the metadata stored in SQL Server and the BLOB. With this capability, you can move the BLOB to cheaper storage than SQL or to a store that is optimized for the type of content you’re working with. SharePoint supports the FileStream provider in SQL Server 2008 and you can plug in your own remote BLOB storage providers if the FileStream provider does not meet your needs.

    Image Property Promotion

    To support rich metadata for the new media content types, SharePoint provides property promotion for images. The metadata for uploaded images is automatically filled in based on the metadata of the image from the source such as size, date taken, and other properties.

    Silverlight Web Part and Media Player

    As mentioned earlier in the chapter, SharePoint supports Silverlight 2.0 out of the box through a Silverlight web part and a Silverlight media player web part. You can just drag and drop the media player web part onto your page and point it to your digital asset. This web part also supports theming, using XAML themes, so that you can change the user interface (UI) for the media buttons and skin the player. In addition, the player supports previewing images so that you can load a static preview image that appears before the user clicks the play button on the video.

    Workflow

    From simple task management to complex business processes, workflow is a critical part of many applications. With 2010, workflow gets a number of new features and better integration with a key workflow design tool: Visio. In addition, many of the challenges from workflow in 2007 are addressed in the 2010 release.

    OOB Modifiable Workflows

    One of the biggest complaints about SharePoint 2007 workflows is that the out-of-the-box (OOB) workflows were not customizable. Therefore, if you wanted to tweak one step in the workflow and you couldn’t do it through the properties or user interface of the OOB workflow, you had to rewrite the entire workflow as a custom one. With 2010, all the OOB workflows are modifiable, so to change or add a step, you just fire up SharePoint Designer or Visual Studio and make your changes.

    Site Workflows

    With SharePoint 2007, your workflow had to run on an item. This limited your ability to be able to run workflows on folders or items that were external to SharePoint but surfaced through the Business Connectivity Services. With 2010, site workflows provide this capability. When you combine this with the external list capabilities, you can build some interesting applications that work with data not stored in SharePoint but stored in databases or line-of-business (LOB) systems.

    Visio Services

    Many business users create workflow diagrams in Visio. They drag and drop their process, draw lines between the boxes, and hope that IT can implement what they’ve drawn. With 2010, you can export the Visio diagram to SharePoint Designer (SPD), which interprets the diagram and breaks it into workflow steps. Then, you can fill in the logic in SPD for the steps, such as the conditions and actions, and deploy your workflow. The nice thing is that the workflow’s status is displayed using the Visio diagram through the new Visio Services. Visio Services, like Excel Services, provides a web-based rendering of your Visio diagrams and even includes data connectivity so that you can have Visio Services refresh the diagram data from your backend systems. The back and forth between Visio and SPD can occur numerous times; it’s not just a one-way export.

    Forms Support in SharePoint Designer

    SPD 2007 supported only ASP.NET forms for user initiation and modification of workflows. This limited the end-user-friendliness of both creating and consuming workflows. With 2010, SPD now fully supports InfoPath for creating workflow forms. This makes it easier for power users to create these forms, as InfoPath is easy to use, and it also makes the forms more powerful because you get the full InfoPath functionality, including data validation, connectivity, and customizability.

    WHAT’S NEW IN FORMS

    SharePoint 2007 provides good support for forms, either web-based or InfoPath-based forms. In SharePoint 2010, many of the enhancements embed forms even deeper into the SharePoint platform so that InfoPath forms can replace many of the default functions for which you would normally have to write web-based forms. These enhancements make InfoPath a critical piece of technology that you should learn and understand.

    In SharePoint, there are default forms for creating and editing list items. You can override the controls on these forms, but it requires coding and numerous administrative tasks. With 2010, you can replace these forms with InfoPath forms, which will be rendered in the browser and on the client. With InfoPath, you can perform advanced logic and even data connectivity in these forms. Also, because InfoPath is rich-client- and web-enabled, these forms work offline if you have the InfoPath client installed and SharePoint Workspace, which is discussed next.

    WHAT’S NEW IN GROOVE (SHAREPOINT WORKSPACE)

    The biggest new feature in the client for SharePoint is SharePoint Workspace (SPW). SharePoint Workspace is actually Groove renamed and rebuilt to be a rich SharePoint client. With SPW, you can synchronize your SharePoint lists, libraries, and forms, and work with these items offline. In fact, you can use BCS and InfoPath to synchronize LOB data to the client to work with that data and those forms offline and synchronize that data back to the LOB system. Outlook still supports synchronizing libraries offline, but with the new SPW, you’ll find that you use SPW as your primary client, especially if you’re working over slow connections or there is latency to your server, as SPW can work in a primarily offline mode.

    WHAT’S NEW IN CLOUD SERVICES

    Unless you’ve been on a desert island for the last year, you have heard of SharePoint Online, which is part of Office 365. Office 365 is the next generation of the Business Productivity Online Suite that included SharePoint Online, but the BPOS service ran only SharePoint 2007. With Office 365, SharePoint Online upgrades to SharePoint 2010. Before you get too excited, remember that SharePoint Online does not have all the functionality of SharePoint on-premises, especially from a developer standpoint. You can’t have full trust code and you don’t have access to Central Administration so, while you can build applications on SharePoint Online, you may not be able to build the same applications that you built on-premises in SharePoint Online.

    In addition to Office 365, understanding Windows Azure is quickly becoming a critical for SharePoint developers. Windows Azure can plug into SharePoint applications through technologies such as Silverlight, jQuery, REST, OData, or others. In addition, you can leverage technologies such as Azure Connect to connect the Azure cloud service to on-premises SharePoint sites and data in a secure way. Azure allows SharePoint Online developers to work around some of the limitations of SharePoint Online by building Azure applications and hosting those applications in SharePoint Online.

    SUMMARY

    This chapter covered a broad view of the new capabilities in SharePoint 2010. It provided a good overview to help level set the functionality in the product so as you write your code, you can determine which features will meet your application’s needs. Throughout the rest of the book, you’ll learn more details about these new features and learn how to program against these features to build robust and very capable SharePoint 2010 applications.

    Chapter 2

    Developer Tools for SharePoint 2010

    WHAT’S IN THIS CHAPTER?

    Understanding the different tools available to SharePoint developers

    Exploring what’s new in SharePoint Designer 2010

    Using the new SharePoint tools in Visual Studio

    Getting the most from these tools in your SharePoint development projects

    Although SharePoint 2007 has a decent set of tools, including out-of-the-box customizations, SharePoint Designer, and Visual Studio Extensions for WSS, the 2010 family enhances these tools and makes it easier for developers to design, develop, test, and deploy their solutions. The main enhancements come in SharePoint Designer (SPD) and Visual Studio (VS), both of which had major overhauls in the 2010 release. SPD now provides much more granular control of editing by end users so that they do not cause issues on your sites, a redesigned user interface to make the creation of SharePoint artifacts easier, and support for the Web Solution Package format so that you can upsize SPD projects to Visual Studio (VS). Visual Studio now has a completely revamped developer experience built into the VS environment.

    Unlike Visual Studio Extensions for WSS (VSeWSS), which was a separate download, many of the tools you need to quickly develop SharePoint applications are right in VS. This chapter takes a deeper look at each of these tools so you will understand what they can do for development with SharePoint.

    OOB DEVELOPER EXPERIENCE

    With SharePoint 2010, the out-of-the-box (OOB) experience has been enhanced in several ways for the developer customizing the SharePoint environment, including easier customization of sites, a new web part page design experience, and new web parts.

    Customization of sites is one of the main actions that a developer needs to perform, whether that is modifying the master page, creating and designing the layout, or just working with web parts on the page. With 2010, all of these actions have become easier in a number of ways.

    For example, you can now customize application pages with your master page so that the look and feel of the application pages are the same as the rest of your site, unlike in SharePoint 2007. In addition, SharePoint protects you from broken master pages by having some default application pages, such as the site administration page, fail back to a simple master page if your dynamic master page is broken.

    In terms of creating and designing your layouts, SharePoint now has a much richer layout experience because of the new user interface. If you are working with publishing pages, you can quickly change the layout of your publishing pages with a single click. The Ribbon user interface makes it easier for you to work with your page design and web part properties by showing contextual tabs based on the web parts that you click. The ability to discover part properties for both the developer and end user of web is improved by this new Ribbon interface, and with your custom web parts, you can perform the same steps as the out-of-the-box (OOB) features and web parts to add your actions to the Ribbon. Figure 2-1 shows a custom Ribbon menu for OOB features.

    FIGURE 2-1

    Getting your web part onto the page and customizing it has changed in SharePoint 2010. The web part gallery, which appeared on the right side of the page in 2007, has been replaced with a web part menu on the Ribbon for inserting your web parts. With this new user interface, you can select your web parts and insert them into the page as in the previous version. However, you can now also preview the web part before inserting it into the page to make sure it is the web part you are looking for. Figure 2-2 shows the new web part insert functionality with preview.

    FIGURE 2-2

    The modify web part settings have not changed from SharePoint 2007 to SharePoint 2010. They continue to appear on the right-side tool pane, allowing you to customize the properties for the web part, change its appearance, or modify its layout.

    One of the nice things about SharePoint development is that you get a number of OOB web parts to speed your development so that you do not have to write everything from scratch. While the following isn’t an exhaustive list of all the web parts in SharePoint, it includes a number of key new web parts that you should be aware of: Silverlight, Visio, Chart Viewer, the Chart web part, Web Analytics, the Tag Cloud, the InfoPath form, the Media web part, and the Profile Browser.

    The Silverlight web part is exactly what its name implies — a generic Silverlight web part for you to add to your site. You point the web part to your Silverlight package, a XAP (XAP is the file extension for Silverlight applications) file, and then your Silverlight application is rendered in the site. In SharePoint 2007, you had to hack the web.config and adjust a number of other settings to get Silverlight to work, but with 2010, the Silverlight web part is baked right in with no configuration changes needed.

    The Visio web part is used to graphically display Visio files. You use this in combination with Visio Services to display static or data-connected Visio diagrams. SharePoint uses the Visio web part as part of its workflow technology to graphically display the status of a workflow. Figure 2-3 shows the Visio web part used in an application.

    FIGURE 2-3

    You may be wondering what the differences are among the Chart Viewer, Chart web part, and Excel Services. Before I cover that, let’s quickly discuss the business problem these web parts are trying to solve, which is to graphically display data in an easy-to-consume format such as a chart. You could write your own web parts to do this, but having something available out of the box makes it easier and faster to build an application.

    So, here’s the difference. The Chart Viewer web part is a simple web part that allows you to chart data from a SharePoint list. It doesn’t allow for complex scenarios, formulas, or the like. The Chart web part is a more general-purpose web part that provides a wizard-based user interface and can connect to more datasources, such as the business connectivity services, lists, web part connections, or even Excel Services. Excel Services is the ultimate tool, because it is Excel rendered through SharePoint. It has the most functionality, including spreadsheets, formulas, charts, and data connectivity. The only downside of Excel Services is that it can’t connect to SharePoint data, so for charting data in SharePoint, you must use one of the other web parts.

    The Web Analytics web part uses the web analytics engine in SharePoint to display the most popular content, search queries, or search results on the site. It is customizable so that you can filter by content type, show the popularity rank and trend, and also expose its data via an RSS feed. Whereas before you may have used the Content Query web part to try to figure this out, the Web Analytics web part makes it easier to display this information quickly and reliably in your site.

    The Tag Cloud web part, another new feature in SharePoint 2010, allows you to graphically display the tags in your environment and rank them according to the number of items tagged by making more frequently tagged items appear larger in the cloud than less frequently tagged items. You can specify the length of time to query the system from retrieving all tags regardless of date to tags created as recently as one month ago. In addition, you can specify how to filter the tags: by you, your colleagues, a particular group, or everyone. Finally, you can show the number of times the tag is used in the user interface in addition to the scaling based on the count. Figure 2-4 shows the Tag Cloud web part.

    FIGURE 2-4

    UNDERSTANDING SHAREPOINT DESIGNER 2010

    Right about now, you might be thinking: How can a development book talk about SharePoint Designer? Isn’t SPD the tool for the nonprofessional developer or end users, who break their site with it? Before you jump to conclusions about SPD, take a moment to understand how it can fit into your development tool continuum for SharePoint: SPD 2010 has a number of enhancements that you will want to take advantage of. You can extend SPD with Visual Studio so that it can be a tool you harness for others to use with your solution. And, because SPD has interoperability with Visual Studio, you can upsize your SPD projects to Visual Studio. All of these facts combined make SPD a tool that you definitely want to look at for certain scenarios.

    New User Interface

    The first thing you will notice about SPD is its new user interface. SPD now has the Ribbon UI, which makes it easier to discover the tasks you can perform in SPD against your SharePoint sites. In addition, the navigation of SPD has changed from a raw view of your SharePoint hierarchy to a more refined view of your SharePoint artifacts grouped in a logical way such as Site Pages, Master Pages, Page Layouts, Content Types, Workflows, and so forth. This new view makes navigation and discovery of your SharePoint sites and information architecture easier. Figure 2-5 shows the new user interface for SPD.

    FIGURE 2-5

    Top Ten New Features in SPD

    Because this is a professional development book, you will not see deep coverage of SPD here, but you still should know the top features, beyond the new user interface, that SPD 2010 provides. These include enhancements to workflow design, integration with Business Connectivity Services, and even lockdown capabilities.

    Improved Workflow Design

    One of the first things you will notice when designing workflows in SPD is that the Workflow Designer has been enhanced. The user interface has been streamlined with a simplified wizard that you use to design the steps, allowing you to get more done with fewer clicks. Also, moving to the Ribbon user interface has resulted in the design steps being contained not in the Workflow Designer but in the Ribbon itself, which makes it easier to find the tools you need to perform specific tasks. Plus, you can now start typing your workflow items, and SPD will search for conditions or actions, based on what you’re typing. It’s a sort of IntelliSense built into SPD. Figure 2-6 shows the new user interface for the Workflow Designer.

    FIGURE 2-6

    The other enhancement in workflow design is the support for parallel branches in your workflow. You can have particular blocks of your workflow run in parallel with the main parts of your workflow. This is useful if you want a particular action to occur while you are performing another action. In addition, SPD now supports nested actions so that you can show those nested actions in a simpler way through the user interface.

    Another nice addition to SPD for workflow design is the new Task/Approval Designer. With an SPD workflow, you often want to be able to create a task or approval process. The previous version was very simplistic in the way you could assign a task to a user and have them complete that task. With SPD 2010, there is an entirely new user interface for task creation and assignment, as shown in Figure 2-7.

    FIGURE 2-7

    As you can see in the figure, you can design exit criteria for a task, such as what happens when someone approves or rejects the task. This exit criteria is a workflow itself, so you get the richness of the SPD workflow for your task subprocesses. With 2010, tasks also throw events that you can capture in SPD, such as when a task is assigned, pending, expired, deleted, or completed. All of these events are workflows as well, so you can log the task, email the task, or perform other workflow actions based on what your application requires.

    Figure 2-8 shows the overall task process that you can modify in SPD. If you don’t like the way the default task process is handled and want to add additional steps or change criteria, you can modify the approval process, which as stated earlier is just a workflow that you can modify. The main point to remember about the Task Process Designer is that it implements everything as workflows that you can modify.

    FIGURE 2-8

    Task design in the Task Designer is enhanced by options that provide you with the ability to control the settings of a task in a richer way than in previous versions. A major new feature is the ability to have SPD automatically set the permissions of a task so that only the person to whom the task is assigned can read and edit it. Because SPD uses a SharePoint task list only to store tasks, people who access the task list cannot see the tasks assigned to others in the workflow and cannot approve or change the tasks.

    The last piece for the task design is the forms used for your tasks. Because SPD is integrated with InfoPath, you can modify your task forms with InfoPath and use its power to perform database lookups or more complex logic. Figure 2-9 shows the customization of a workflow task form with InfoPath 2010. Make sure to publish the workflow, because SPD won’t generate your forms before you do this step.

    FIGURE 2-9

    Another new capability of workflow design is the ability to take an entire step in a workflow and use impersonation to interact with it as the workflow’s author. If you don’t know the history here, it may not sound that impressive, but with the previous version, all workflows were run in the context of the user who initiated the workflow, not the workflow’s author, so the workflow had permission to do only what the person who started the workflow could do. Previously, people hacked around this by making workflows start as the system account, which is bad for security, as the system account has access to everything. Therefore, users could see things that they were not intended to see by running particular workflows.

    Impersonation of the workflow’s author is a serious step, so you must consider what allowing someone to use impersonation means. The user will have access through your workflow actions to everything that

    Enjoying the preview?
    Page 1 of 1