D
Derek Timothy
Hi folks I have strange problem using cmd.exe from asp code
I am trying to save the results of an FTP command into a text file. When I
run this command from the command line of the web server it creates the text
file OK and it contains the results of the FTP commands.
ftp.exe -s:test.ftp > c:\tempfile.txt
However when I run it from asp using cmd.exe, it creates the file
c:\tempfile.txt but there is nothing in it.
set oScript=Server.CreateObject("WSCRIPT.SHELL")
oScript.run("cmd.exe /c ftp.exe -s:test.ftp > c:\tempfile.txt")
Any ideas why?
Thanks a lot,
Derek
I am trying to save the results of an FTP command into a text file. When I
run this command from the command line of the web server it creates the text
file OK and it contains the results of the FTP commands.
ftp.exe -s:test.ftp > c:\tempfile.txt
However when I run it from asp using cmd.exe, it creates the file
c:\tempfile.txt but there is nothing in it.
set oScript=Server.CreateObject("WSCRIPT.SHELL")
oScript.run("cmd.exe /c ftp.exe -s:test.ftp > c:\tempfile.txt")
Any ideas why?
Thanks a lot,
Derek