It's possible RT returns values, but it doesn't return them to the command line. If it did, i'd be able to get them using the following:
Problem is I'm not an experienced programmer, so I have no clue how to do this with applications that don't display values on the command line.Code:System.Diagnostics.Process proc = new System.Diagnostics.Process(); //create my process proc.EnableRaisingEvents = false; //String sMyPath = Environment.CurrentDirectory; proc.StartInfo.FileName = "devcon.exe"; //name of file to run proc.StartInfo.Arguments = " "; proc.StartInfo.RedirectStandardOutput = true; //setup redirection proc.StartInfo.UseShellExecute = false; //redirect from shell to proc.StartInfo.CreateNoWindow = true; //hide shell proc.Start(); String cmd_out = proc.StandardOutput.ReadToEnd(); MessageBox.Show(cmd_out);
The above example is a piece of code I used to make a GUI for devcon, which is a microsoft command line utility that lets you manipulate devices in your computer - basically device manager, but via command line. Instead of displaying the info at the command line prompt, the code redirects it into a string, and then I can parse it, to read status, find device id's ect. In the above example it just displays it in a messagebox. (i made the GUI to turn off devices in my laptop to extend battery live... it's a lot easier then going to device manager to disable them).
Unfortunately this is the way I have the GUI run rivatuner to set the voltage control registers, and it doesn't redirect anything for me to parse, cause it doesn't display the info in the dos box (command line). it displays it in it's own GUI (rivatuner).
Like I said, I'm n00b at programming. So if you have any visual C# examples that work to return RT value, i'll be glad to try to make it work.
Bookmarks