This is the code from the class library:
proc.StartInfo = new ProcessStartInfo (CmdPath, "+ an -b");
proc.StartInfo.RedirectStandardOutput = true;
proc.StartInfo.CreateNoWindow = true;
proc.StartInfo.UseShellExecute = false;
proc.Start ();
proc.WaitForExit ();
This works fine, as I would expect when called from a console test application. When I take the same library and call the method from the ASP.NET web service, it just hangs.
Is there something I am missing here, perhaps permission? The ASPNET service has access to the folder where the EXE is located, and I see that it is running in the task manager, although it does nothing.
If someone tells me what I'm doing wrong, I would appreciate it. Thanks.
EDIT : Sorry for the lack of information. CmdPath goes to the command line interface for our scheduling software. I pass commands based on the documentation they provided. I have one way to get the list of tasks and another method to start the task .... hmm idea. The client usually uses Active Directory to log in, I think impersonation will be necessary. Now let's start testing.
EDIT 2 : Ok, now the client will explode with AccessViolation issues. This is obviously a permission issue. If the software uses the built-in AD authorization and I impersonate my AD account, will that be enough? I am doing an impersonation using a tag in web.config.