When trying to load the SharePoint Online PowerShell module into the ISE or an existing shell you may get the error below. Simple problem with a non-obvious error message… The fix is easy… after installing the SharePoint Online Management Shell, run PowerShell or the ISE as Administrator.
PS C:\> Import-Module Microsoft.Online.SharePoint.PowerShell -DisableNameChecking
Import-Module : The specified module 'Microsoft.Online.SharePoint.PowerShell' was not loaded because no valid
module file was found in any module directory.
At line:1 char:1
+ Import-Module Microsoft.Online.SharePoint.PowerShell -DisableNameChecking
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ResourceUnavailable: (Microsoft.Online.SharePoint.PowerShell:String) [Import-Mo
dule], FileNotFoundException
+ FullyQualifiedErrorId : Modules_ModuleNotFound,Microsoft.PowerShell.Commands.ImportModuleCommand
1 comment:
Thanks Mike for your post! It worked like a charm! :)
Post a Comment