I'm trying to start a c# program from a wep api. When i try this under Visual studio develop it runs. After pubishing it on IIS the program does not start. I dont't get any errors, it never runs in the catch block. Why doesn't the "process.Start" work?
public class ServerController : ApiController
{
[ActionName("starthilfe")]
public Info GetHelp()
{
Info inf = new Info();
try
{
Process P = new Process();
P.StartInfo.FileName = @"D:\Videos\Deutsch\WindowsFormsApp1.exe";
P.Start();
inf.TextFeld1 = "Hilfe erfolgreich gestartet";
return inf;
}
catch (Exception ex)
{
inf.TextFeld1 = "EXEPTION";
inf.TextFeld2 = ex.Message;
return inf;
}
}
}