View Single Post
Old May 9th, 2006, 03:42 AM
dzagore2 dzagore2 is offline
Registered User
Join Date: Apr 2006
Location: , , .
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default Script execution...

 first here is the code I have >
...I didn't include the variables declaring and initialization here..

Set objScript = Server.CreateObject("WSCRIPT.SHELL")
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objTextFile = objFSO.CreateTextFile(Server.MapPath("test.ftp"))

objTextFile.WriteLine "open " & ftp_address
objTextFile.WriteLine ftp_user
objTextFile.WriteLine ftp_pass
objTextFile.WriteLine "lcd " & Server.MapPath(".\downloaded")
objTextFile.WriteLine "cd " & ftp_location
objTextFile.WriteLine "binary"
objTextFile.WriteLine "get " & ftp_file
objTextFile.WriteLine "bye"

Set objTextFile = Nothing

strCMD = "ftp -s:"&Server.MapPath("\test.ftp")


Set objFSO = Nothing
so the problem is when I call this script from the asp page it doesn't execute a download of the file, but when I do it with ftp -s: \MyPath\test.ftp command in the command line on the server it executes just fine, what could be the problem here ?