I created a windows service with Process.start(filepath) in it. But it is neither working nor showing any errors. I got the file as a background process in the task manager.
I tried BackgroundWorker with DoWorkEventHandler delegate to start the process. But I failed to start the process.
I tried BackgroundWorker with DoWorkEventHandler delegate to start the process. But I failed to start the process.
I also tried with ProcessStartInfo and UseShellExecute as false but it is not working.
- Process prs = new Process();
- string strAppPath;
- strAppPath = "C:\\WINDOWS\\SYSTEM32\\notepad.exe";
- prs = Process.Start(strAppPath);
- prs.WaitForExit();
- base.Stop();

Amit MohantyRank #112 · 20K reputationPosted Aug 19, 2019, 3:14 AM EDT
Sonu GuptaRank #1,261 · 1.4K reputationPosted Aug 20, 2019, 9:58 PM EDT