Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


RE: Saving ftp directory listing to databse

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,38463
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> RE: Saving ftp directory listing to databse
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: <<   < prev  1 [2]
Login
Message << Older Topic   Newer Topic >>
 RE: Saving ftp directory listing to databse - 10/10/2006 6:32:44 AM   
  caryma77

 

Posts: 27
Score: 0
Joined: 9/19/2006
Status: offline
yes.  The weird thing is that I am getting the internet.communication error.  What could possibly be calling it? 

(in reply to ehvbs)
 
 
Post #: 21
 
 RE: Saving ftp directory listing to databse - 10/10/2006 6:45:31 AM   
  ehvbs

 

Posts: 2171
Score: 50
Joined: 6/22/2005
From: Germany
Status: offline
Difficult for me to answer that question. Could there be problems with your
FTP server? I'd try

   (1) to use the MS FTP server (with "DFWCU")

    Dim sServer  : sServer  = "10.85.20.85"
    Dim sUser    : sUser    = "username"
    Dim sPWord   : sPWord   = "password"

    ==>

    Dim sServer  : sServer  = "ftp.microsoft.com"
    Dim sUser    : sUser    = "anonymous"
    Dim sPWord   : sPWord   = "caryma77@whatever.com"

   (2) execute

         ftp -i -s:C:\ftpdir.txt > "C:\ftplog.log"

        from the command line, verify that "C:\ftplog.log" contains valid data,
        run the script with "DfWCU" (using the manually created  "C:\ftplog.log")

(in reply to caryma77)
 
 
Post #: 22
 
 RE: Saving ftp directory listing to databse - 10/11/2006 4:53:41 AM   
  caryma77

 

Posts: 27
Score: 0
Joined: 9/19/2006
Status: offline
Got it to work but still having problem with the FTP side.  I manually ran the following command from the command prompt to create the ftpdir.log

ftp -i -s:C:\ftpdir.txt {ip ftp Server} > C:\ftpdir.log

Once the log file was created I changed the DFSW to DfSW and ran the code and it was successful.  For some reason it doesn't like the

CreateObject( "WScript.Shell" ).Run sFTPCmd, SW_SHOWMINNOACTIVE, True

(in reply to ehvbs)
 
 
Post #: 23
 
 RE: Saving ftp directory listing to databse - 10/11/2006 5:06:48 AM   
  ehvbs

 

Posts: 2171
Score: 50
Joined: 6/22/2005
From: Germany
Status: offline
Hi caryma77,

my ftpdir.txt looks like this:

  open ftp.microsoft.com
  anonymous
  ehvbs@vbc.com
  ls -l
  bye

as you see, I use the open command to specify the ftp server. Your working
command line

  ftp -i -s:C:\ftpdir.txt {ip ftp Server} > C:\ftpdir.log

specifies the server via a command line parameter. Could this be the cause
for our difficulties?

(in reply to caryma77)
 
 
Post #: 24
 
 RE: Saving ftp directory listing to databse - 10/12/2006 5:20:15 AM   
  caryma77

 

Posts: 27
Score: 0
Joined: 9/19/2006
Status: offline
I have ran it both ways specifying the server in the ftp command or using the open command.  Same results.  If I run the ftp function manually and comment out the F section then it works but for some reason the code will not create the ftpdir.log file

(in reply to ehvbs)
 
 
Post #: 25
 
 RE: Saving ftp directory listing to databse - 10/16/2006 1:47:56 AM   
  caryma77

 

Posts: 27
Score: 0
Joined: 9/19/2006
Status: offline
ehvbs,

Thanks for all your help and support. I finally got it to work.  I did the following:

change

sFTPCmd = "%comspec% /c ftp -i -s:" + sFCFSpec + " > """ + sLGFSpec + """"

to

sFTPCmd = "command /c ftp -i -s:" + sFCFSpec + " > """ + sLGFSpec + """"

Once again your assitance was greatly appreciated.  The script works like a charm!!!!

(in reply to ehvbs)
 
 
Post #: 26
 
 
Page:  <<   < prev  1 [2]
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> RE: Saving ftp directory listing to databse Page: <<   < prev  1 [2]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts