Failing Script
I've devoured the forums and help topics and I'm still stuck.
Mostly I just end up pulling up the winscp.com prompt after all this. I have a million iterations of trying to get it to work. I'm trying to do this in VBA which is probably where I fall down. Goal is to SFTP a file everynight after a bunch of macros finish running in excel which is why I chose to house it in VBA.
First Iteration
This one doesn't even run the text file.
Any help would be greatly appreciated. Like i said, most of my iterations just open up winscp.com command prompt and I can get it to logon but then they don't execute anything.
Mostly I just end up pulling up the winscp.com prompt after all this. I have a million iterations of trying to get it to work. I'm trying to do this in VBA which is probably where I fall down. Goal is to SFTP a file everynight after a bunch of macros finish running in excel which is why I chose to house it in VBA.
First Iteration
Shell ("""C:\Program Files (x86)\WinSCP\WinSCP.com"" /ini=nul ""/script=c:\Users\John Doe\Desktop\RCGWM1.txt""")
option batch abort option confirm off option transfer binary/s open sftp://user:pass@xxxxxxxxxxx lcd "C:\Users\John Doe\Dropbox\HF\Strat" cd /UAT/TradeFile/test put "FILL CSV" Exit
Any help would be greatly appreciated. Like i said, most of my iterations just open up winscp.com command prompt and I can get it to logon but then they don't execute anything.