Quantcast
Channel: SharePoint 2010 - Development and Programming forum
Viewing all articles
Browse latest Browse all 11571

Retrieve document versions content (CSOM)

$
0
0

Hi,

I'm able to retrieve the versions' properties (CSOM) but I have issues to download the previous versions of the files.

I'm using the same code to download the current version of the doc (which works), but I get the following exception with versions:

System.Collections.ListDictionaryInternal: Specified argument was out of the range of valid values.
Parameter name: serverRelativeUrl :    at Microsoft.SharePoint.Client.File.MakeFullUrl(ClientContext context, String serverRelativeUrl)
   at Microsoft.SharePoint.Client.File.OpenBinaryDirect(ClientContext context, String serverRelativeUrl)

I use version.Url as the serverRelativeUrl, which looks like "/_vti_history/512/mysite/myfile.txt". The ClientContext is on the site that holds the document.

I also got the following exception on a 2013 online site:

Server Exception: System.Collections.ListDictionaryInternal:

Cannot invoke HTTP DAV request. There is a pending query. :    at Microsoft.SharePoint.Client.File.OpenBinaryDirect(ClientContext context, String serverRelativeUrl)

Any idea ?

Thanks!


Viewing all articles
Browse latest Browse all 11571

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>