Cant import a module due to "Import-Module : Could not load file or assembly" however the file is present

0

Cant import the module due to the error below, but that file is present.

C:\Users\User.Name> Import-Module AWS.Tools.S3
Import-Module : Could not load file or assembly 'file:///C:\Users\User.Name\Documents\WindowsPowerShell\Modules\AWS.Tools.Common\4.1.12.0\AWSSDK.Core.dll' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)
At line:1 char:1
+ Import-Module AWS.Tools.S3
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [Import-Module], FileLoadException
    + FullyQualifiedErrorId : FormatXmlUpdateException,Microsoft.PowerShell.Commands.ImportModuleCommand

Also tried Add-Type -Path to the file, but same error.

Does anybody know what I can try and do to fix this?

powershell
powershell-module
aws-powershell
asked on Stack Overflow May 21, 2021 by user13721641

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0