So let’s continue where the last post left off and finish the high-level pimping of the PivotViewer control…
If you want to follow along then you need to locate the PivotViewerSample code that shipped with the control. By default it is here for the August 2010 release:
C:\Program Files (x86)\Microsoft SDKs\Silverlight\v4.0\PivotViewer\Aug10\Source\PivotViewerSampleXapCode.zip
In the previous post the sample code showed you how to hide the left side Filters Panel and the right side Info Panel. It showed you also how to alter the background to help brand the control’s appearance.
The original code was a bit raw so I have put together a small demo application that wraps the functionality up into the custom PivotViewer class override. The sample allows you to toggle the Visibility of the tiles as well as the filters and information panels.
The custom properties can simply be used as in this sample:
C# Sample: Hide/Show the collection tiles
And the background can be set to ImageBrush like this:
C# Sample: ImageBrush
The sample has a button to toggle the background between:
You can try out the sample Silverlight application here:
Here is the source code for you to play with, if you find it useful, let us know. We have extended the PivotViewer control in other ways to.