I'm stuck while creating an application whose abstract work is to copy some file from host machine to network machines shared folder,
I'm doing something like this in c#
string lscmd = "robocopy "+ lsCurentWorkingDirectory+ " \\\\CPU219\\Test$ " + lsFileName;
ProcessStartInfo ProcessInfo;
ProcessInfo = new ProcessStartInfo("cmd.exe", "/c " + lcmd);
ProcessInfo.CreateNoWindow = true;
ProcessInfo.UseShellExecute = False;
process = Precess.Start(ProcessInfo);
process = Precess.Start(ProcessInfo);
ProcessInfo.CreateNoWindow = true;
ProcessInfo.UseShellExecute = False;
process = Precess.Start(ProcessInfo);
process.waitforExit();
When I'm runing this code through windows services its get stuck at process.WaitforExit(), and when I'm running this by normal console application, it works well.
plz help me
VulpesPosted Nov 13, 2014, 9:16 AM
waqar ahmed imamuddinPosted Nov 13, 2014, 12:32 AM
VulpesPosted Nov 12, 2014, 6:10 AM
waqar ahmed imamuddinPosted Nov 11, 2014, 11:38 PM
VulpesPosted Nov 11, 2014, 9:51 AM