The past couple of weeks I'm working with Silverlight controls embedded in SharePoint 2007.
For one of the controls I need to retrieve the data using the Search Query Web Service.
This was working perfectly in the development environment. But when deploying the control to the production environment it didn't work.
The past couple of weeks I’m working with Silverlight controls embedded in SharePoint 2007. For one of the controls, I need to retrieve the data using the Search Query Web Service.
This was working perfectly in the development environment. But when deploying the control to the production environment it did not work.
With the introduction of the August Cumulative Update for SharePoint 2007 (KB973399) we encountered “System.NullReferenceException: Object reference not set to an instance of an object.” on all pages inheriting from MySitePublicWebPartPage.
With the introduction of the August Cumulative Update for SharePoint 2007 (KB973399) we encountered System.NullReferenceException: Object reference not set to an instance of an object. on all pages inheriting from MySitePublicWebPartPage.
As can be seen in the stack trace the error occurs from a call by the ProfilePropertyImage control, which is on the page by default.
The cause
This call was not present in the control prior to the august update, so let’s take a look at the description of the update (KB973409).
A Shared Services Provider administrator edits the About me property or the Picture property to make the property display “Only me”. However, these properties continue to be visible when the profile owner sets their As Seen By option to “Everyone”, “My Colleagues”, “My Workgroup” or “My Manager” on their own Person.aspx page.
So, this explains why the control was changed, it now looks if the image should be rendered for the current visitor of the page.
As we all know SharePoint's code is never about defensive programming and so is the case here if there is no ViewState Property available, it will return a null. And of course, there is no check anywhere for that.
But this code works for the default person.aspx page, so the setter for this property has to be called somewhere. Analysis of the code shows only the AsSeenBy class ever calls the setter. As this control is on the person.aspx page by default, the property is set and that page works fine. As we do not have this control on our page, we get a NullReferenceException.
The solution
If you are bound to the August release the solution is simple: add the AsSeenBy control to your page.
But what if you do not want to have the control on your page? We get lucky, because if you do not make it visible it will still work, so add:
I was having trouble with the clock in my Linux Hyper-V VM’s. The time was constantly drifting forward. Using NTP only slowed the drift a bit down but often NTP gave up after several days.
I was having trouble with the clock in my Linux Hyper-V VM’s. The time was constantly drifting forward. Using NTP (Network Time Protocol) only slowed the drift a bit down but often the NTP service gave up after several days.
I’m running Linux in Hyper-V VM’s since the launch of the Windows Server 2008 RTM. It was quite complex to get performance and support for the network drivers.
Recently with the launch of Windows Server 2008 R2 there are also new Linux Integration Components which also work for 2008 RTM.
Here is the list of steps to install CentOS with these components.
I am running Linux in Hyper-V VM’s since the launch of the Windows Server 2008 RTM. But in the beginning it was quite complex to get real performance and support for the network drivers.
Recently, with the launch of Windows Server 2008 R2, there are also new Linux Integration Components which also work for Windows Server 2008 RTM. So here is the list of steps to install CentOS with the integration components.
Mount the CDROM and copy the contents mkdir -p /mnt/cdrom mount /dev/cdrom /mnt/cdrom cp -rp /mnt/cdrom /opt/linux_ic umount /mnt/cdrom
Build the drivers cd /opt/linux_ic ./setup.pl drivers If you get the message No kernel-xen-devel or kernel-source package installed. You must install this package before installing the drivers. edit the setup.pl file and change the following: -$kernel = `rpm -q kernel-xen-devel`; +$kernel = `rpm -q kernel-devel`; If everything went OK you can now see a new nic (network interface controller) called seth0 using ifconfig
You can now remove the Legacy Network Adapter.
Remember, every time you update the kernel you have to run the setup.pl drivers command.