PowerShell Script

This forum is not monitored by the SmartFTP staff. If you have a license please contact technical support by email.
Post Reply
syoder
Posts: 2
Joined: Mon Oct 05, 2009 11:37 pm

PowerShell Script

Post by syoder » Tue Oct 06, 2009 6:45 pm

I about have way through creating a FTP script using PowerShell and I am stuck. When I reach the section to for proxy setting I run into an error.
I have looked at a couple scripts but, no matter how I change it I still get the error message. I am missing something and need some help

The following lines fail with or with out "ProxyType" or "FTPProxyType"
$objFTPConnectionMTA.ProxyType = sfFTPLib.ProxyType.enumProxyType.ftpProxyTypeNone;
$objFTPConnectionMTA.FTPProxyType = sfFTPLib.FTPProxyType.enumFTPProxyType.ftpFTPProxyTypeNone;

This is the error message I am getting
The term 'sfFTPLib.ProxyType.enumProxyType.ftpProxyTypeNone' is not recognized as a cmdlet, function, operable program, or script file. Verify the term and try again.
At C:\MyScripts\FTPTest.ps1:45 char:95
+ $objFTPConnectionMTA.ProxyType = sfFTPLib.ProxyType.enumProxyType.ftpProxyTypeNone <<<< ;
+ CategoryInfo : ObjectNotFound: (sfFTPLib.ProxyT...tpProxyTypeNone:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException

Note: $objFTPConnectionMTA = new-object -comobject sfFTPLib.FTPConnectionMTA is loaded and works. The issue is on the sfFTPLib side.

mb
Posts: 12030
Joined: Thu Oct 11, 2001 1:24 pm
Display name: Mat (SmartFTP)
Contact:

Re: PowerShell Script

Post by mb » Tue Oct 06, 2009 7:05 pm

Can you send the complete script to support at smartftp.com

Thank you
Regards,
SmartFTP

syoder
Posts: 2
Joined: Mon Oct 05, 2009 11:37 pm

Re: PowerShell Script

Post by syoder » Tue Oct 06, 2009 8:05 pm


Can you send the complete script to support at smartftp.com

Thank you
Regards,
SmartFTP

mb
Posts: 12030
Joined: Thu Oct 11, 2001 1:24 pm
Display name: Mat (SmartFTP)
Contact:

Re: PowerShell Script

Post by mb » Tue Oct 06, 2009 9:04 pm

Hm your last post was empty.

Post Reply