I'm trying to use xcopy with cmd.exe and for some reason it just isn't working. I can call cmd.exe and pass it the parms of "net send mypc hello" and it will work flawlessly but xcopy will not. I can do this in winforms but with webforms its a different story.
I gave the aspnet user admin rights and full rights the the folder but still nothing. Does anyone have any ideas on why this is not working? I am trying to keep from having to use impersonation. thanks in advance, von
Dim startInfo As System.Diagnostics.ProcessStartInfo = New System.Diagnostics.ProcessStartInfo
Dim p As System.Diagnostics.Process
startInfo.FileName = "C:\\windows\\system32\\cmd.exe"
startInfo.Arguments = "/c xcopy c:\test\test.txt c:\test\test.exe\"
p = System.Diagnostics.Process.Start(startInfo)
p.WaitForExit()
von
Member
90 Points
19 Posts
System.Diagnostics.Process with cmd.exe not working?
Sep 03, 2003 01:05 PM|LINK
Dim startInfo As System.Diagnostics.ProcessStartInfo = New System.Diagnostics.ProcessStartInfo Dim p As System.Diagnostics.Process startInfo.FileName = "C:\\windows\\system32\\cmd.exe" startInfo.Arguments = "/c xcopy c:\test\test.txt c:\test\test.exe\" p = System.Diagnostics.Process.Start(startInfo) p.WaitForExit()