2. Makeiteasier to createcustom data view webparts Introductionto data view webparts in SPD2010 Advancedmethod to work with data view webparts. Suggestsome tools youcanuse Goals SharePoint 2010 Advanced Data View Webparts 8 September, 2010
3. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts The default dataview webpart Difficult to style (css classes, …) Difficult to edit/manipulate (complex xslt) A lot of assumedrequiredfunctionality (clickability, integrated menu’s, …)
4.
5. Fiddlerwww.fiddler2.com Stylus Studio 2010 XML Enterprise Suitewww.stylusstudio.com Tool of choice to decodehtml Firefox & Firebug Tools I use SharePoint 2010 Advanced Data View Webparts 8 September, 2010
6. SharePoint 2010 Advanced Data View Webparts 8 September, 2010 Demonstration All steps of the demo are included in the next slides.
7. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts Creating a Minimal Data view webpart Open the page you want to edit in AdvancedEditing mode in SPD Insert a new “Empty Data View” into the page
8. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts Intercept the XML data for the webpart Click on “click here to select a datasource”, and select the datasourceyou want to workwith: Start up Fiddler, and click on “refresh data source” in SharePoint designer. Youshouldsee 4 HTTP requests show up in fiddler.
9. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts Identify the HTTP requestthatretreives the XML
10. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts HTML-decodethis data and save itsomewhere. Clean up the file, we’llonlyworkwith the tags “dsQueryResponse” and it’s contents
11. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts Open a new document in Stylus studio 2010 Set the source XML URL to the xml file youjustcreated Set Processor to .NET XslTransform Click “Ok” to confirm
12. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts Start writingyourown minimal xsltusing Drag&drop values Intellisense Press to seeyourchangeson the fly
13. 8 September, 2010 SharePoint 2010 Advanced Data View Webparts Applyyournewstylesheet to the data view webpart Copy the xsltfromStylus Studio to the webpart properties of your data view webpart: