System.Dia​gnostics.P​rocessStar​tInfo Class Not Working

2 visualizaciones (últimos 30 días)
joan de la cruz
joan de la cruz el 31 de Mayo de 2017
Comentada: Eric Lau el 8 de Ag. de 2019
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 comentario
Eric Lau
Eric Lau el 8 de Ag. de 2019
Hi joan,
Did you get this working? I am having a similar issue with a recent windows 10 install.

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Introduction to Installation and Licensing en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by