VBA Site contains VBA code to create macros in WORD EXCEL ACCESS OUTLOOK



1) Uploading file to FTP using WinSCP

 

Call Shell("C:\Windows\System32\cmd.exe /c start C:\""Program Files (x86)""\WinSCP\WinSCP.com /command ""open login:password@ftp.name.com"" ""cd subfolder"" ""put C:\YourFolder\YourFile.txt"" ""exit"" ")

Call Shell("C:\Windows\System32\cmd.exe /c start C:\""Program Files (x86)""\WinSCP\WinSCP.com /command ""open ftps://login:password@ftp.name.com"" ""cd subfolder"" ""put C:\YourFolder\YourFile.txt"" ""exit"" ")

with string

file = "C:\YoutFile.txt"

Call Shell("C:\Windows\System32\cmd.exe /c start C:\""Program Files (x86)""\WinSCP\WinSCP.com /command ""open ftps://Login:Password@ftp.name.pl"" ""cd subfolder"" ""put """ & file & """exit""")

Shell ("taskkill /F /IM WinSCP.com")



2) Downloading file from FTP using WinSCP

 

Call Shell("C:\Windows\System32\cmd.exe /c start C:\""Program Files (x86)""\WinSCP\WinSCP.com /command ""open login:password@ftp.name.com"" ""cd subfolder"" ""get YourFile.txt C:\YourFolder\YourFile.txt"" ""exit"" ")

Call Shell("C:\Windows\System32\cmd.exe /c start C:\""Program Files (x86)""\WinSCP\WinSCP.com /command ""open ftps://login:password@ftp.name.com"" ""cd subfolder"" ""get YourFile.txt C:\YourFolder\YourFile.txt"" ""exit"" ")



Dodaj komentarz






Dodaj

© 2013-2024 PRV.pl
Strona została stworzona kreatorem stron w serwisie PRV.pl