21 October 2010

How do I – Solve the problem where the MS Word Document Information Panel dropdown does NOT show all the values from the source SharePoint list

I was asked this question last night. “Why doesn’t all my lookup list values show up in the Document Information Panel in Office?”
This one is a tricky little one to try and debug. Unless you know a little about what is going on in the plumbing of SharePoint and how it works behind the scenes, you may spend more time hunting this than you should. Hopefully this post will save you some time. 😉
Back to the problem…
Let’s start with the source list against which the lookup is done. Let’s define a list called “TestDropdownSource”. There’s nothing special about this list. Just add a couple of records to the list.
image_29_3D505C6E
As you can see here, the All Items view for this list is just showing the first 3 entries, even though we have 5 records in the list.
image_30_3D505C6E
If we look at the definition of the view in question, and then scroll all the way down and expand the “Item Limit” section, we see that I defined the number of items to display as 3 for the purpose of this demo.
image_31_3D505C6E
Now we create a new document library called “TestSource”. We add a new column to the library and use a lookup to our source list. The library looks like this:
image_32_3D505C6E
When we look at the Columns, we notice the “LookupValue” field.
image_33_3D505C6E
When we look at the definition of the “LookupValue” field, we notice that it gets its information from the “TestDropdownSource” list’s Title field.
image_34_3D505C6E
If we now add a new document to the document library (which is set to use Word), Word will open and the Document Information Panel will show the “LookupValue” field. When we open the dropdown list, we notice that ONLY 3 items are shown.
image_35_3D505C6E
That is the problem that we are trying to solve. To fix this, we go back to the list definition for the “TestDropdownSource” list.
We open the default view’s definition. In this case, we only have the “All Items” view, but if you have more views defined, you are interested in the default view. That is because Word’s implementation of the SharePoint web services uses the default view of the source list rather than a targeted view.
Once in the view’s definition, we are going to set the number of items back up to 100.
image_36_3D505C6E
A quick check and we see all 5 items displayed in the view.
image_37_3D505C6E
Now simply create a new document again (or open an existing one).
image_38_3D505C6E
And check the DIP… all should be well… 🙂
image_39_3D505C6E

Cheers
C

No comments:

Post a Comment

Comments are moderated only for the purpose of keeping pesky spammers at bay.

Microsoft Authentication Library (MSAL) Overview

The Microsoft Authentication Library (MSAL) is a powerful library designed to simplify the authentication process for applications that conn...