SIGN UP MEMBER LOGIN:    
ARTICLE

Chart Web Part in SharePoint 2010

Posted by Vijai Anand Articles | SharePoint June 25, 2011
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.
Reader Level:

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
 

Login to add your contents and source code to this article
share this article :
post comment
 

Hello Vijai, Thank you for this detailed article. I can grasp overall functionalities of Chart Web Part very easily. By the way, I have one question. We have a custom list which consist of one column named "Your choice" with choices "A", "B" and "C". And many people access to that list and select the one of those choices like polling. I would like to show the results of that polling with the bar chart by using Chart Web Part (such as 10 items for "A", 5 items for "B" and 2 items for "C"). Because of your detailed explanation, now I know how to add a web part and connect to that list but the graph can not show the result appropriately. I would like to show the number of items in "Y-field" and the choices in "X-field" but there is not "Your choice" column in the drop-down box of "Y-field" so I cannot set it as "Y-field". Perhaps Chart Web Part cannot count the number of items? I apologize for my poor English in advance. Could you please help me? Fuji

Posted by Fuji Ogawa Jul 03, 2011

Thank you Mahesh sir:-)

Posted by Vijai Anand Jun 27, 2011

Good work!

Posted by Mahesh Chand Jun 25, 2011
Team Foundation Server Hosting
Become a Sponsor
PREMIUM SPONSORS
  • The leading .NET charting control now features PDF, Flash and Silverlight export, visualization of large datasets and more. Deliver true charting functionality to your BI, Scorecard, Presentation or Scientific apps. Download evaluation now.
    Get 2 Months Free of ASP.NET Hosting for Only $4.95/month! Receive FREE MS SQL and MySQL Databases Including ASP.NET 4/3.5, MVC 3.0, Silverlight 4, Windows 2008/IIS 7.0 Plus FREE IIS 7 Modules. Host UNLIMITED ASP.NET Web Sites - Click Here!
Nevron Gauge for SharePoint
Become a Sponsor