FIX: Can't download files from SharePoint Server 2013 document libraries by using SharePoint Services adapter

Symptoms
Assume that you use the SharePoint Services adapter in Microsoft BizTalk Server 2013. When you download files from SharePoint Server 2013 document libraries that contain managed metadata columns by using the adapter, you receive the following error message:
The Windows SharePoint Services receive adapter has failed to process the SharePoint file FileName. The following error has been encountered:
[System.InvalidCastException] Unable to cast object of type 'System.Collections.Generic.Dictionary`2[System.String,System.Object]' to type 'Microsoft.SharePoint.Client.Field'.
Error code: 12310
Once you have addressed the issue causing this problem, you can undo the check-out for this file and the adapter will try to process it again.
This error was triggered by the Windows SharePoint Services receive location or send port with URI wsss://[...]?ViewName=ToBizTalk.
Windows SharePoint Services adapter event ID: 12457

Cause
The issue occurs because BizTalk Server 2013 uses SharePoint 2010 client libraries. However, SharePoint 2013 client libraries are expected.
Resolution

Cumulative update information

This issue was first fixed in the following cumulative update of BizTalk Server:
Workaround
To work around this issue, use one of the following workarounds:
  • Don't use managed metadata columns in SharePoint Server 2013 document libraries.
  • Replace the referenced SharePoint 2010 assemblies with SharePoint 2013 assemblies from the SharePoint 2013 server:
    • Microsoft.SharePoint.Client, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c
    • Microsoft.SharePoint.Client.Runtime, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e94
    Then, create the following binding redirection in BizTalk configuration files (BTSNTSvc.exe.config and BTSNTSvc64.exe.config):
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">      <dependentAssembly>        <assemblyIdentity name="Microsoft.SharePoint.Client"                          publicKeyToken="71e9bce111e9429c"                          culture="neutral" />        <bindingRedirect oldVersion="14.0.0.0"                         newVersion="15.0.0.0"/>      </dependentAssembly>                  <dependentAssembly>        <assemblyIdentity name="Microsoft.SharePoint.Client.Runtime"                          publicKeyToken="71e9bce111e9429c"                          culture="neutral" />        <bindingRedirect oldVersion="14.0.0.0"                         newVersion="15.0.0.0"/>      </dependentAssembly></assemblyBinding>
Status
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
References
For more information about the service packs and cumulative update list for BizTalk Server, see KB 2555976: Service pack and cumulative update list for BizTalk Server.

For more information about BizTalk Server hotfixes, see KB 2003907: Information about BizTalk hotfixes and cumulative update support.
Properties

Article ID: 3050885 - Last Review: 10/09/2015 23:38:00 - Revision: 1.0

Microsoft BizTalk Server 2013 Branch, Microsoft BizTalk Server 2013 Developer, Microsoft BizTalk Server 2013 Enterprise, Microsoft BizTalk Server 2013 Standard

  • kbqfe kbfix kbsurveynew kbexpertiseadvanced KB3050885
Feedback