Sylvain
08-15-2002, 08:14 AM
Hi all,
I have a problem with the command copy in a batch file. My web page call the batch file. In my batch file I have just 1 line. A copy command. It's working fine on our intranet server who is on NT. But our futur intranet is on Windows 2000 and the same page doesn't works. Why?
The structure is I have a web page on the server who have IIS. On the same server I have a share who content a batch file. In the same place of the batch file I have a file with extention 850. The batch file content a copy command that copy the file on the same directory but with the extention DID.
I checked the securitu on both share and it's the same, but is doesn't working. I have no error on the result of my asp page.
This is the code of my asp page:
<%@ Language=VBScript %>
<%
RESPONSE.WRITE "Begin " & Time & "<br>"
set wshell = server.createobject("wscript.shell")
wshell.run "f:\shrapp\DirectoryX\Sylvain\Test.bat"
set wshell = nothing
RESPONSE.WRITE "The End<BR>"
%>
<HTML>
<HEAD>
</HEAD>
<BODY>
</FORM>
</BODY>
</HTML>
The batch file content:
copy f:\shrapp\DirectoryX\Sylvain\File1.850 f:\shrapp\DirectoryX\Sylvain\File1.DID
I think its a security problem but I'm not sure. I repeat, the same code is working fine on NT server but not on Windows 2000 server.
It's still 2 days in work on that and I didn't fine the problem.
I have a problem with the command copy in a batch file. My web page call the batch file. In my batch file I have just 1 line. A copy command. It's working fine on our intranet server who is on NT. But our futur intranet is on Windows 2000 and the same page doesn't works. Why?
The structure is I have a web page on the server who have IIS. On the same server I have a share who content a batch file. In the same place of the batch file I have a file with extention 850. The batch file content a copy command that copy the file on the same directory but with the extention DID.
I checked the securitu on both share and it's the same, but is doesn't working. I have no error on the result of my asp page.
This is the code of my asp page:
<%@ Language=VBScript %>
<%
RESPONSE.WRITE "Begin " & Time & "<br>"
set wshell = server.createobject("wscript.shell")
wshell.run "f:\shrapp\DirectoryX\Sylvain\Test.bat"
set wshell = nothing
RESPONSE.WRITE "The End<BR>"
%>
<HTML>
<HEAD>
</HEAD>
<BODY>
</FORM>
</BODY>
</HTML>
The batch file content:
copy f:\shrapp\DirectoryX\Sylvain\File1.850 f:\shrapp\DirectoryX\Sylvain\File1.DID
I think its a security problem but I'm not sure. I repeat, the same code is working fine on NT server but not on Windows 2000 server.
It's still 2 days in work on that and I didn't fine the problem.