Using SharePoint 2007 user profile service with Silverlight

When developing a Silverlight application that required the use of the user profile web service provided by SharePoint 2007, I discovered a rather frustrating bug.

Adding the service as a .NET 2.0 web reference, it will function as one would expect. However, when adding it as a service reference in a Silverlight project (as Silverlight has certain requirements of the web services it consumes) the bug kicks in.

It seems that the WSDL provides elements in the wrong order and also the autogenerated classes fails to handle objects of type like GUID (when calling methods they will fail stating that they don’t know how to handle the GUID values).

This only applies when reading data from the web service, when writing back it seems to function normally.

One solution I’ve found to work around this is to implement your own class for calling the web service and do the parsing yourself. I’ll probably do a post later on how I did this.

Advertisements

One Response to Using SharePoint 2007 user profile service with Silverlight

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: