Monday, October 27, 2008

Report Viewer Web-Part Parameters

When attempting to pass parameters to the Report Viewer Web Part, you need to ensure that the report parameter type is set to Prompt, otherwise the connection interface never makes the parameter selectable in the UI.

Friday, October 24, 2008

SPWeb Property Bag

The contents of the property bag are persisted when a site is saved to an STP, so you need to check for the existence of a property in the bag before attempting to add it..

Monday, October 20, 2008

Storing Data in the SPWeb Property Bag

To ensure that data is persisted to the property bag, call the Update() method, just as you would for any other SharePoint object.

Cannot Import Web Part

If you can’t import a web part you have written – check that the web-part class is actually public !!!

Wednesday, July 09, 2008

Running SharePoint OM code in an MSI on Windows Server 2008

I ran into a problem whilst attempting to install some SharePoint code on a Windows Server 2008 machine. Changes to the way Vista and Server 2008 deal with the security associated with MSI installs meant that we were failing with a repeated security problem.

Turned out that a change to the local policy for elevation was required to allow the installer to run in the context of the current user...

Using the group policy snap-in for MMC, we had to navigate to Local Computer Policy / User Configuration / Administrative Templates / Windows Components / Windows Installer, then set the value of the Always install with Elevated privileges to Disabled.

Wednesday, June 04, 2008

Using Matching Items in a SharePoint Business Data Column

I was using Nick Swan's excellent BDC Meta Man to build some definition files for sample SQL DBs to connect to SharePoint.

I was trying to get the Matching Items function working in the Business Data Column, so that a partial entry will return a set of possible matches....

bestmatch

On the main Finder method, generated by BDC Meta Man, I added a filter descriptor to support the UsedForDisambiguation switch, and this seemed to make the difference.

<FilterDescriptors>
<FilterDescriptor Type="Wildcard" Name="Customer Name" >
<Properties>
<Property Name="UsedForDisambiguation"
Type="System.Boolean">true</Property>
</Properties>
</FilterDescriptor>

</FilterDescriptors>