Problem with MSOnline

Issue #47 resolved
Former user created an issue

I get the following error when I run import-module MSOnline:

[ERROR] Import-Module : Could not load file or assembly 'Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of [ERROR] its dependencies. The system cannot find the file specified. [ERROR] At C:\Source\VSTFS\ADUserManagement\ADO365Scripts\ADO365Scripts\AssignCRM.ps1:1 char:1 [ERROR] + Import-Module MSOnline [ERROR] + ~~~~~~ [ERROR] + CategoryInfo : InvalidOperation: (:) [Import-Module], FileNotFoundException [ERROR] + FullyQualifiedErrorId : FormatXmlUpdateException,Microsoft.PowerShell.Commands.ImportModuleCommand [ERROR]

This error only happens when I am using my VS2017 instance. It works in my VS2015 instance of Powershell Tools and also works in Powershell ISE. I have tried re-installing the Tool into the VS2017 instance. I have also re-installed the MSOnline module.

Any ideas?

Thanks,

Comments (2)

  1. Adam Driscoll

    Can you please run [Newtonsoft.Json.JsonConvert].Assembly to see what version is currently loaded? It looks like there is a conflict between the Newtonsoft.Json versions.

  2. Log in to comment