Tuesday, November 29, 2011

Working with Sarepoint Designer 2010

This blog provides a high-level overview of the features and capabilities of Sharepoint Designer 2010. You'll take a look through the various menus and see some examples of how to perform several common task, including the following:

  • Managing your sites
  • Working with data sources
  • Views and forms
  • Workflows
  • Branding
Who should use Sharepoint Designer?

SPD is a very powerful tool, and despite many of the improvements for SPD 2010 that simplify its use, in the wrong hands it can cause problems. Whether you are  a Sharepoint administrator, developer, or end user, make sure that when you first start using SPD, you are doing so from a place where you can do no harm.

With that public service message out of the way, who should use SPD? The tool is intended to be used by site owners and power users to create and add functionally to Sharepoint, without needing to know how to write code. The same reasons that make SPD an ideal tool for end users also make it an ideal tool for developers and administrators.

Introduction to Shareopoint Designer 2010

The name  "Sharepoint Designer" suggests that it is a tool for website designers, but customizing your site's look and feel is just one of many tasks that SPD is capable of doing. Perhaps a better name would be something like "Sharepoint Management Studio" because SPD 2010 acts as a central location to manage your Sharepoint sites.

There have been a number of improvements to SPD 2010, starting with a new UI. Like everything else in Sharepoint 2010, SPD has been updated with a new user interface that introduces the fluent UI, otherwise known as "the Ribbon." By now this isn't a new concept. Aside from the Ribbon, the menus themselves have been updated to make it easier to do many common tasks. Those familiar with SPD 2007 would often use the tool to make changes to web pages or create a custom workflow. With SPD 2010, most of the functionality from the previous version is still there (and improved), but it is now possible to manage your Sharepoint sites directly from the tool. In this section we'll discuss the basics you'll need to begin using Sharepoint Designer 2010.

Requirements for Using SPD 2010

SPD 2010 will indeed be available as a free download, at http://www.microsoft.com/spd. Following are the necessary requirements:

  • Supported operating systems - Windows 7; Windows Server 2003; Windows Server 2003 Service pack 1; Windows Server 2003 Service Pack 2; Windows Server 2008 R2; Windows Server 2008 Service Pack 2; Windows Vista Service Pack1.
  • Computer and processor - 500 MHz processor or higher
  • Memory - 256 MB of RAM or higher
  • Hard disk - 2.5GB minimum
SPD 2010 works only with Sharepoint 2010. If you try to open your MOSS sites with SPD 2010, it won't work. Although this may be frustrating for some users, it was a decision made by the SPD product team in order to make it possible to implement all of the changes for the new version of the project.

In environments where SP 2007 and SP 2010 are both installed, it might be necessary to have SPD 2007 and SPD 2010 installed side by side on the same machine. If this applies to you, make sure you install the same version of SPD 2010 that you did with SPD 2007. Because SPD 2007 only came in x86, if you wanted to install SPD 2010 on the same machine it would be necessary to install SPD 2010 x86.

Overview of the New UX

Click  Start --> All Programs --> Sharepoint, then click Microsoft SPD 2010.

The first screen that opens is referred to as the Sites place. This screen is divided into four self-explanatory areas: Open Sharepoint Site, New Sharepoint Site, Recent Sites, and Site Templates.

In the Site Templates section, by default you'll only see three options for templates: Blank Site, Blog, and Team Site (see Figure 22-1). Clicking on one of these templates will open up a dialog that enables you to create a new site once you specify a URL. If you want to create a new site based on a different template that isn't specified, you can click the More Templates button and type in the URL of a site that has more options. For example, typing in the URL for a site created using the Enterprise Wiki template would allow you to choose from additional templates such as Enterprise Wiki, Publishing Site, and so on.

















Figure 22-1

If this is the first time you've opened SPD, the Recent Sites area will be blank and you'll need to click the Open Site button. Once the Open Site dialog opens, you can type in the address of your site in the format of http://contoso or http://contoso/subsite and then click Open.

Your site will open to what is referred to as the setting page, shown in Figure 22-3, which displays high-level information such as the title, description, URL, Sharepoint version number, permissions, subsites, etc. The setting page for the site is the starting point from which all changes to your site can be made. Previously, when SPD 2007 opened, user were presented with a multi-paned interface that contained a blank HTML page and other areas that allowed you to edit the parts of your page (see Figure 22-4). SPD 2010 has an updated user interface that puts more of a focus on Sharepoint itself. All aspects of your Sharepoint site should be easily accessed from this page.


















Figure 22-3
















Figure 22-4

The  user interface, shown in Figure 22-5, is divided into three main areas:

  • Navigation - This pane shows the various components that make up a site, including lists, libraries, master pages, page layouts, workflows, content types, etc. Clicking on one of the links will take you to a Gallery page.
  • Gallery and Summary - This is the main area of the screen, which displays the lists of each component type along with summary information.
  • Ribbon - As with the rest of Sharepoint, electing an object causes the Ribbon to display menus and options for customizing that object.
The navigation panel is the most common way to navigate the site. No matter which gallery has been clicked, the navigation panel is always visible. You can quickly jump to the settings page by clicking the Site link (listed first in the navigation) or jump to any of the other areas of the site.





















Figure 22-5

Restricting Access to Sharepoint Designer

Sharepoint administrators everywhere can breathe a sigh of relief, because SP 2010 now provides much tighter control over how SPD can be used in an organization with the following settings:

  • Enable SPD - Determines whether SPD can be used at all.
  • Enable Detaching Pages from the Site Definition - Allows edited pages to be customized, which detaches them from the site definition.
  • Enable Customizing Master Pages and Layout Pages - Removes the Master Page link from the navigation pane and prevents users from updating master pages and layout pages.
  • Enable Managing of the Web Site URL Structure - Removes the All Files link from the navigation pane.
These new options enable organization to control SPD 2010 at the level appropriate to their requirements. SP 2010 allows access to SPD to be controlled at two different levels:

  • Central Administration - Accessed from the General Application Settings menu, this enables farm administrators to control SPD at the web application level. Disabling the options here prevents site collection administrators from enabling the functionality.
  • Site Collection - Accessed from the Site Collection Administration section in Site Settings, this enables site collection administrators to control SPD access for Designers and Site Owners.
The following example walks you through the process of updating the SPD settings from Central Administration:

  1. Open Central Administration from your Sharepoint server by clicking Start --> All programs --> Microsoft SP 2010 products --> Microsoft Sharepoint 2010 Central Administration.
  2. Click General Application Settings in the left navigation.
  3. From the Sharepoint Designer section, click Configure SPD settings (see Figure 22-10).















Figure 22-10

4. From the settings page, select the appropriate web application from the drop-down at the top right. By default, all the options should be selected. Leave the first box checked, which enables the use of SPD, but remove the checks from the other boxes, as shown in Figure 22-11. Click OK.
















Figure 22-11

5. To test the changes, navigate to the URL of the site collection in your web browser to be used for testing, and log in as a site collection administrator, In this example, we use http://contoso. In order for this example to work, the ID that is used must be a site collection administrator.

If you were to test with an account that has more permission, such as a farm administrator account, you might not notice any changes. Since administrator accounts have more rights to the site collection, these changes won't impact their ability to use SPD.

6. From the Site Actions button, choose Edit in SPD.
7. SPD should open. Note that the Master Page, Page Layouts (only shows in sites with Publishing enabled), and All Sites links should be missing from the left-hand navigation pane. If the links are still there, verify that you are logged in as a site collection administrator, not a farm administrator. You can check by  clicking the icon in the bottom-left corner of the SPD window, which displays the name of the logged-in user.

Also, if you were to click Site Pages and try to edit the home.aspx, you'll notice that Advanced mode is grayed out. the page can only be edited in Normal mode, which means that only content in Web Part zones can be edited.


8. For the next step, we are going to test what happens when you completely disable SPD access. Close the instance of SPD that you were using for the last example. It's OK to leave your web browser open.

9. Repeat steps 1-3 and remove the check from the Enable SPD box. Press. OK.

10. Repeat step 5. Now when you try to open SPD, you should see the prompt shown in Figure 22-11.








Figure 22-11

What Can You Do With Sharepoint Designer 2010?

  1. Data Sources: The old adage that 'Content is king" is just as true today with SP 2010 as it ever was. SPD 2010 can be used to create and manage data sources whether the data is coming directly from SP or from external sources. Data Sources is the term used by SPD 2010
  2. Lists and Libraries: The most basic types of data in Sharepoint are lists and document libraries; and in terms of SPD 2010, the concepts do not change at all. However, creating and managing lists and libraries is much easier with SPD 2010 than in the past. Clicking the Lists and Libraries link in the navigation in your site with SPD 2010 will open up the List and Libraries gallery. The gallery shows all of the lists and libraries associated with this site. The gallery interface makes it easy to create new lists and libraries based on template, create your own with custom columns, or update existing ones by adding columns or modifying the settings.
  3. Data Source Connections: Clicking the Data Sources link in the navigation will open the gallery, which at first glance looks exactly like the Lists and Libraries gallery. Although lists and libraries are data sources, the important difference in this gallery can be seen if you look at the Ribbon -  you'll notice several new options. In many cases, the data that you want to interact with in your Sharepoint site is actually coming from a source outside of Sharepoint. The following types of data source connections are supported:

    - External database
    - SOAP Web Service
    - REST Web Service or RSS Feed
    - XML File Connection
    Clicking the corresponding button in the Ribbon of SPD will open a wizard that enables you to quickly connect to each of the different data sources. Once you've connected to the data sources, SPD 2010 can be used to combine the information from multiple sources into a single view. Many would refer to this as creating a mashup, but in Sharepoint terminology this is referred to as a a composite application. An example would be if you wanted to combine product information stored in a SQL Server database with customer information stored in another system, which is exporting to an XML file. All of the data is coming from different places and combined into a single view by using SPD 2010.
  4. External Data Integration:SP 2010 greatly enhances the capability to connect to Line-of-business (LOB) systems - using a feature that has been renamed Business Connectivity Services (BCS). SPD 2010 can now be used to create the connections into LOB systems such as SQL Server databases, PeopleSoft, SAP, and more. Once the connections are made, the information can be surfaced as an external content type (ECT) in an external list. For example, if you were to connect to your customer database in SQL Server and add it as an external list, you could update the content in SQL Server directly by making changes to the data in Sharepoint. The BCS now enables changes from Sharepoint to be written back to LOB system.
  5. Using SPD 2010 to Create an External List: The goal of this example is to walk you through the steps for creating an external list with SPD 2010. BCS is convered in more detail in next page. For this example, we'll be using AdventureWorks sample databse. If you do not yet have it installed, you can download it from http://msftdbprodsamples.codeplex.com/. Be sure to download the correct version based on the version of SQL Server you have installed. The examples in this chapter are shown using the SQL Server 2008 R2 databases.

    After downloading and installing the databse, follow these steps:

    1. Open SPD 2010 and open your Sharepoint site.
    2. From the navigation pane, click the link for the External Content Types gallery.
    3. Click the External Content Type button in the Ribbon (see Figure 22-12)
    4. Enter a Name and Display Name. Clicking the words 'New external content type" will allow you to edit the name. For this example, enter Northwind Products as the value of Name Field and Products as the value of Display Name Field.
    5. Click the link that says 'Click here to discover external data sources and define operations" (see Figure 22-12), which will open a new page that will enable you to configure the connection to your external data source.











Figure 22-12











Figure 22-13

6. From the new screen, click the Add Connection button located in the upper left hand corner of the center panel. This will open up a series of windows that will walk you through the process of configuring the connection to external data source. With previous versions of Sharepoint, this process needed to be done either by hand, which was extremely complex, or through the use of third-party products.

6. From the first pop-up, select the External Data Source Type as SQL Server and click OK.

7. Next, specify the Database Server and Database Name for the database to which you want to connect. (see Figure 22-14) from the second pop-up. Click OK.















Figure 22-14

9. When the Data Source Explorer is loaded, expand the Table sections, select the Product table, right-click on it, and click Create All Operations (see Figure 22-15). You might receive a warning when you expand the tables saying that some columns have unsupported data types. if you do receive the warning, press OK to move past it and continue with the demo. it will not impact the rest of the steps.






















Figure 22-15

10. The All operation window will open, which enables you to specify more details about how the external content type works. For this example, leave all of the default settings and click Finish.

11. you'll notice that there's now a green check mark displayed under the External Content Type Operations section, indicating that everything is working as expected. However, before you can use the external content type, it is necessary to save it. To do so, press the Save icon in the upper-left corner of the screen. , which will save it to the Business Data Connectivity Metadata store.

12. Click the Create profile page button in the Ribbon to create a profile page that will be used to display the information from external data when it is shown in Sharepoint.

13. Once Sharepoint has connected to the data source, you'll make an external list so that you can interact with the data in Sharepoint. To do this, click Lists and Libraries in the Site Objects panel in SPD.

14. From the Ribbon, click the External List button.

15. From the External Content Types Picker, choose Products and click Ok.

16. Enter products as the name for the new external list and click OK.

17. if you browse to your Sharepoint site and click on the list, the content from the SQL Server table should be returned. If everything looks good, skip to step 20. If this is the first time you've configured a BCS connection, you'll probably get an error stating "Access denied by Business Data Connectivity". To resolve this, open Central Administration and go to Application Management and then click Manage service applications. Click the Business Data Connectivity Service. Place a check in the box next to the new connection you made, and click the Set Object Permissions button in the Ribbon.

 18. The Set Object Permissions dialog, shown in Figure 22-16 will open. In the top box, specify the accounts to grant permissions to and then click the Add button.

Figure 22-16





19. Once the account has been added, select the permissions the account should have. For this example, you've just added the account that will be browsing the external list. This account was granted all permissions and the option to Propagate permissions to all methods was checked. Click OK.

The content in the external list should now be displayed without the error. In a production environment, it would be necessary to specify the users and/ or groups who have permission to read from and write to this data source.

20. The external list should display the information from the SQL table. As you can, it looks very similar to a Sharepoint list, and in fact it can be edited just like one. Select the first item called Test Product with a product number of Ar-5381. The Ribbon will change to display new options. Click the Edit item button.


    1 comment:

    1. Thanks for this great overview that explains most of the features and capabilities of Sharepoint Designer 2010. I have bookmarked this article so as to take help from it.
      electronic signature for sharepoint

      ReplyDelete