Differences
This shows you the differences between the selected revisions of the page.
2021-03-26 | 2021-08-26 | ||
no summary (72.222.125.27) | Document the necessity of unblocking the files after installation, before they can be used. (208.84.91.38) | ||
Line 33: | Line 33: | ||
===== [[install]] Installing the Assembly ===== | ===== [[install]] Installing the Assembly ===== | ||
- | First, you need to install the WinSCP .NET assembly. In most cases, all you need to do is [[library_install#downloading|download]] the ''WinSCP-X.X.X-Automation.zip'' package and extract it along with your PowerShell script. | + | First, you need to install the WinSCP .NET assembly. In most cases, all you need to do is [[library_install#downloading|download]] the ''WinSCP-X.X.X-Automation.zip'' package and extract it along with your PowerShell script. Generally you only need ''WinSCPnet.dll'' and ''WinSCP.exe''. |
- | The version of ''WinSCPnet.dll'' in the root of the package is .NET Framework build of the assembly. It can be used with Windows PowerShell only. With PowerShell (Core) 6/7, you have to use .NET Standard build of the assembly, which is located in the ''netstandard2.0'' subfolder. | + | Since the files are coming from an external source, you also have to **unblock** them (just once, unless you reinstall). You can do this manually, using the File Explorer to modify the file properties (on the General tab). Or you can do this from PowerShell, with the ''[[ps>microsoft.powershell.utility/unblock-file|Unblock-File]]'' cmdlet. But after unblocking, you must restart the PowerShell console. |
+ | |||
+ | The version of ''WinSCPnet.dll'' in the root of the Zip package is the .NET Framework build of the assembly. It can be used with Windows PowerShell only. With PowerShell (Core) 6/7, you have to use the .NET Standard build of the assembly, which is located in the ''netstandard2.0'' subfolder. | ||
For specific cases, read full instructions to [[library_install|installing the WinSCP .NET assembly]]. | For specific cases, read full instructions to [[library_install|installing the WinSCP .NET assembly]]. |