Open matsla opened 5 years ago
Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.
@matsla , did you get this working, and if so would you mind sharing the steps needed to get this up and running?
@kenneho , To solve the assembly binding issue with 'Newtonsoft.Json' after update SharePointPnPCoreOnline to latest version:
- Delete the local NuGet packages folder
Thanks for you input. By deleting the local NuGet packages folder, you're referring clearing all caches like dotnet nuget locals all --clear
?
@kenneho , It's the packages folder under your solution folder i.e ...source\'your vs solution'\packages. This folder contains all the NuGet packages used by the solution and all versions.
I'm also having this trouble. Though I'm trying to create a Teamsite without O365 group var teamContext = await spContext.CreateSiteAsync( new TeamNoGroupSiteCollectionCreationInformation(fullUrl, title) ); I tried the solution above @matsla but with no success
Is there any progress in solving this issue?
This code below is now throwing an exception when using TeamSiteCollectionCreationInformation with parameter Owners. It seems anyway that att owners defined in owners array are addedd to site. If i remove the owners parameter array it works fine.
The code works with SharePointPnPCoreOnline 3.10.1906 but this version is dependent of Newtonsoft.Json 11.0.1. As we are using Azure Functions and upgrading to Newtonsoft.Json 11.0.1 from 10.0.3 will get following error:
System.IO.FileNotFoundException: Could not load file or assembly 'Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The system cannot find the file specified. File name: 'Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'
Is it possible to build SharePointPnPCoreOnline 3.10.1906 and later versions with Newtonsoft.Json 10.0.3 to get this to work with azure functions?
SharePointPnPCoreOnline 3.8.1904 (Newtonsoft.Json 10.0.3)
var authManager = new OfficeDevPnP.Core.AuthenticationManager();
ClientContext ctx = authManager.GetSharePointOnlineAuthenticatedContextTenant( "https://xxxx.sharepoint.com", "xx@xx.onmicrosoft.com", "xx");
string[] owners = new string[2]; owners[0] = "x@x.onmicrosoft.com"; owners[1] = "y@y.onmicrosoft.com";
var teamSiteContext = await ctx.CreateSiteAsync( new TeamSiteCollectionCreationInformation { Alias = "TEST4", DisplayName = "TEST4", Description = string.Empty, IsPublic = false, Lcid = 1033, Owners = owners });
=> Exception is throw
Stack Trace:
Message:
Category
[X ] Bug [ ] Enhancement
Environment
[X ] Office 365 / SharePoint Online [ ] SharePoint 2016 [ ] SharePoint 2013
Thanks for your contribution! Sharing is caring.