System.Diagnostics.ProcessStartInfo Class Not Working
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I have been using the System.Diagnostics.ProcessStartInfo Class from the MSDN .NET Framework within MATLAB to run some .exe files that are saved in a directory. The Code I am using is below:
startinfo = System.Diagnostics.ProcessStartInfo('cmd.exe',sprintf('/c "%s"',File));
startinfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;
proc = System.Diagnostics.Process.Start(startinfo);
This code runs perfectly on my own machine and on many other user's machines as a part of a larger compiled standalone application. However, I've run into an issue recently when users try to run the program on newer machines with Windows 10 installed. The error message seems to indicate that System.Diagnostics is not a recognized command or function. From my research, I've found that this error message is usually due to the .NET Framework not being installed or not the correct version on a particular machine. However, I have verified that at least in once case, the .NET Framework is installed (version 4.6).
Has anyone else experienced this?
1 Kommentar
Eric Lau
am 8 Aug. 2019
Hi joan,
Did you get this working? I am having a similar issue with a recent windows 10 install.
Antworten (0)
Siehe auch
Kategorien
Mehr zu Introduction to Installation and Licensing finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!