Chart Web Part in SharePoint 2010


Chart web part is a new feature in SharePoint 2010 which is used to create static and dynamic charts. In this article we will be seeing how to create an out-of-box chart web part in SharePoint 2010.

Add the Chart web part:

  • Go to the SharePoint site.

  • Go to Site Actions = Edit the Page.

  • In the ribbon interface, go to Editing Tools = Insert = Web Part.

  • In the Categories, select Business Data = Chart Web Part.

    Untitled-1.gif

  • Click on Add.

  • A sample dummy chart will be displayed as shown in the following

    Untitled-2.gif

We will be seeing how to create a chart by connecting to the following data

  • Connect to a list.

  • Connect to another web part.

  • Connect to Excel Services.

Connect to a SharePoint List:

  • Click on Data & Appearance.

    Untitled-3.gif

  • You could see the following options as shown in the following.
    Untitled-4.gif
  • Click on "Connect Chart to Data".

  • In the Data Connection Wizard select "Connect to a list" option.

    Untitled-5.gif

  • Click on Next.

  • In the List Connection, select the site and the list.

    Untitled-6.gif

  • Click on Next.

  • You can view all the data and you can configure the filter the data as shown in the following.

    Untitled-7.gif

  • Click on Next.

  • In the "Bind Chart to Data" section, you can choose the X field and Y field and lot of other configurations can be made in this section.

    Untitled-8.gif
  • Click on Finish.

  • You could be able to see the chart displaying the SharePoint list items as shown in the following

    Untitled-9.gif

Customize the chart:

  • Click on Data & Appearance.

    Untitled-10.gif

  • Click on "Customize your chart".

  • Select the Chart type and click on Next.

    Untitled-11.gif
  • You can change the chart appearance as shown in the following.

    Untitled-12.gif
  • Click on Next.

  • Chart Element Properties.

    Untitled-13.gif
    Untitled-14.gif
  • Click on Finish.

  • My chart looks like the following

    Untitled-15.gif

  • Advanced Properties:

    Untitled-16.gif

Connect to Excel Services:

  • In this section, we will be seeing how to connect to the excel services.

  • I have created a named range in the excel workbook which contains the following information.

    Untitled-17.gif

  • I have uploaded the excel workbook to the "Shared Documents".

    Untitled-18.gif

  • In the Chart web part that we have created, go to "Data & Appearance" = Connect Chart to data".

  • Select "Connect to Excel Services" option.

    Untitled-19.gif



  • Enter the Excel workbook path http://serverName:1111/hr/MP3/Shared%20Documents/Rank.xlsx and enter the range.

    Untitled-20.gif

  • You could see the values retrieved from Excel workbook.

    Untitled-21.gif

  • Chart connected to excel services:

    Untitled-22.gif

Similarly you could connect to the another web part and display the chart with those data.

Untitled-23.gif
 

Up Next
    Ebook Download
    View all
    Learn
    View all