Closed flaajimi closed 1 year ago
Looks to me the module is not imported. I see you have used the code to import it, but maybe it's not actually importing. Use Get-Module
and see if it actually exists in your session.
I just grabbed the latest and seems to be working fine for me:
I Have anothe message :
Windows 8.1
It seems like your system is blocking something perhaps. I am unable to reproduce this issue.
But for starters I would update WMF, you have a very very old version of PowerShel. WMF 5.1 came out quite long ago: https://www.microsoft.com/en-us/download/details.aspx?id=54616
I have a W8.1, the module is installed on
Im not really sure what to say on this issue. I can't reproduce it, and this module has been around for like 7+ years and has over 1M downloads and this issue hasn't been reported until now. And the errors you are sharing suggest the module isn't even loading, so it not really anything to do with the logic inside it, its not getting that far. This leaves me to believe it's something with your system. And to me, it seems like something is being blocked. maybe the script module as well as the assembly itself. Check eventvwr and see if there is any errors that stand out there after you trying the Import-Module
command.
Did you update your version of WMF? 5.0 is very old, 5.1 came out still in the days of windows 7. you could also try pwsh. this module is compatible with both.
It's OK now thanks
Can you share what you did to fix the issue should it come up for someone else.
Hi,
I've downloaded an installed your plugin through the Install-Module cmdlet.
When I'm trying to run the code in your Example 1, with my server, user and password of course, I get a Powershell error:
New-WinSCPSessionOptions : The term 'New-WinSCPSessionOptions' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Any ideas on what I might have configured incorrectly on my side, or is there a know problem that causes this error?