Results 1 to 2 of 2

Thread: Help with FTP and Shell command

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2006
    Posts
    2

    Help with FTP and Shell command

    http://www.bygsoftware.com/Excel/VBA/ftp.htm

    I trying to write a VB program to FTP some files and I came across the script on the above website. I seem to be having a problem with this piece of code:

    ' Invoke Directory List generator
    Shell (strDirectoryList & ".bat"), vbHide '', vbMinimizedNoFocus

    No matter what I do I receive the error:
    Error message: "Run-time Error 5 - Invalid Procedure Call or Argument"

    My bat file and txt file all have correct detail (as far as I can tell).

    I am running VB 6.3

  2. #2

    Thread Starter
    New Member
    Join Date
    Sep 2006
    Posts
    2

    Re: Help with FTP and Shell command

    I finally figured it out... The problem was due to the path and the fact that it had spaces. Once I changed the path to something w/o spaces the shell command worked fine!

Posting Permissions

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



Click Here to Expand Forum to Full Width