Live demo: SharePoint, XML files, and Flash charts

FlashCharts

XML driven components are a favorite among designers of dynamic Web sites. They allow to dissociate content from rendering, and greatly facilitate the site maintenance. The most popular are Flash charts, although other technologies are available, like Silverlight.

You can use such components in SharePoint: upload the flash component (e.g. PieFlash.swf) and the data (e.g. PieData.xml) to a document library, then insert the html/JavaScript code in the source editor of a Content Editor Web Part.

In addition, and it is actually the point of this post, SharePoint offers a convenient way to update xml files: the Data Form Web Part. Note that setting up a Data Form Web Part requires SharePoint Designer.

To see it in action, go to my live demo. Note that I am not making credentials publicly available, please contact me by e-mail if you want to play with the form.

Maybe you didn’t know that XML files could be edited directly from within SharePoint pages? If so, the demo page also includes a tutorial on how to set up the Data Form Web Part using SharePoint Designer.

XML files vs. SharePoint lists

Instead of an XML file, another standard approach is to store the data in a SharePoint list. You can then pull the list content in XML format to render the chart.

The advantage of XML files is that they are easier to set up. It just takes a couple minutes to upload the file to SharePoint and link it to a Data Form Web Part. With a SharePoint list, you would have to write the code that grabs the list XML and transforms it into a format that the component can read.

On the other hand, the list approach will be better if you want to benefit from specific SharePoint features (e.g. alerts, version history and permissions at the item level).

My live demo is sponsored by FusionCharts (version 3). Note that the previous version, FusionCharts v2, is available for free (22 chart types).

Advertisements

8 thoughts on “Live demo: SharePoint, XML files, and Flash charts

  1. Pingback: Links (6/15/2009) « Steve Pietrek – Everything SharePoint and Office

  2. If you choose list option, how to query your list and especially the value of a column for an item ?

  3. When I upload your Donut.xml file and click to show data, it doesn’t show me anything. It simply is greyed out and says “The server returned a non-specific error when trying to get data from the datasource…” It seems to do that with all XML files I point to.

  4. Pingback: XML and Flash charts – FAQ « Path to SharePoint

  5. Is there any way to set up the data form web part without using SharePoint designer?

    I manage an intranet site where I want to get information from SharePoint lists to be (automatically and constantly) written to an xml file, which is then read by flash components.

    It’s impossible for me to get SharePoint designer access and I don’t want to go through IT to get this done

    Any ideas?

    cheers,

    John

  6. I am hoping that someone out there can assist. I have a site with multiple child sites all which have an identical list in Gantt view displayed on their home pages. I am trying to roll up all of their information into a global view of the data. I have created a Linked Data source and connected that to a Data Form webpart which displays the data nicely. I would like to display a consolidated Gantt on the parent page showing all of the regional projects. I thought I might be able to do this with FusionCharts. Is there a way to create and XML stream in the correct format to connect the dynamic data from the Data View web part to the FusionChart Gantt. Any alternative solutions would be appreciated as well. Thank You.

Comments are closed.