Lists.GetVersionCollection Method
[SoapDocumentMethodAttribute("http://schemas.microsoft.com/sharepoint/soap/GetVersionCollection", RequestNamespace="http://schemas.microsoft.com/sharepoint/soap/", ResponseNamespace="http://schemas.microsoft.com/sharepoint/soap/", Use=SoapBindingUse.Literal, ParameterStyle=SoapParameterStyle.Wrapped)] public XmlNode GetVersionCollection ( string strlistID, string strlistItemID, string strFieldName )
Parameters
- strlistID
A string that contains the ID of the list.
- strlistItemID
A string that contains the ID of the item.
- strFieldName
A string that contains the name of the field.
Return Value
An XML fragment that contains the version information, and that can be assigned to a System.Xml.XmlNode object.Unless I have missed something there's a major problem with this method.
Version information data returned by the method is not formatted in an invariant culture format. It will be formatted as of the current web (SPWeb) Regional settings.
Considering that it is not possible to retrieve SPWeb regional settings through web services, it is therefore not possible to parse properly the data without knowing in advance the regional settings of the SPWeb.
Another drawback of the current method is the impossibility to retrieve version information for all (or specified) columns of an item at once.
Say you would like to retrieve version information for 400 items having 8 columns (for doing some reporting or analytics on an Issue Tracking list for instance), you will need to call the web service 3200 times.
Hopefully, an updated method will be available in some service pack?! :)
Update:
It looks like you can get regional settings through the "RegionalSettings" element returned by the GetList method.
Still that would obviously be much more comfortable to have a method that would return version information for all the specified column of an item using a similar approach as the GetListItems method.
- 5/30/2008
- Frederic Enesys
- 6/2/2008
- Frederic Enesys