+ Reply to Thread
Results 1 to 2 of 2

Problem executing WinSCP Code thru SHELL

  1. #1
    Forum Contributor
    Join Date
    10-02-2008
    Location
    Berkeley, CA
    MS-Off Ver
    Windows 2007
    Posts
    105

    Problem executing WinSCP Code thru SHELL

    I have a batch file, FTP.Bat, in c:\Temp:
    > Del zFTP.Txt
    > winscp /script=zFTP.Scp /log=zFTP.Txt
    > cscript c:\temp\test.vbs
    > Exit
    and Test.vbs contains MailBox("OK")

    When I execute it either as a straight batch file, from the Start_Run line, or as a batch file thru the VBA Shell, I see the "OK" message from cscript.

    But when I execute the batch file thru the VBA Shell Command
    Call Shell("c:\Temp\FTP.Bat")
    then neither the "Del" nor the "Winscp" lines get executed.


    Any idea what's going on?

    Mac, Berkeley, CA
    Last edited by CaptMac; 11-18-2010 at 03:51 PM. Reason: Closing this.

  2. #2
    Forum Contributor
    Join Date
    10-02-2008
    Location
    Berkeley, CA
    MS-Off Ver
    Windows 2007
    Posts
    105

    Re: Problem executing WinSCP Code thru SHELL

    To make this work thru VBA Shell, you have to be explicit about all file locations: ie., put complete Folder addresses on them.

    Mac

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1