Hy,
I want to use "msinfo32 /nfo path"
My code is:
.......
string OutputFolder = Environment.GetFolderPath(Environment.SpecialFolder.Desktop)
string arg = @"/nfo " + Path.Combine(OutputFolder, Environment.MachineName + ".nfo");
infoProcess.StartInfo.FileName = @"C:\Program Files\Comon Files\Microsoft Shared\MSInfo\msinfo32.exe";
infoProcess.StartInfo.Arguments = arg;
infoProcess.Start();
................
This code does nothing :(
Help pls
Loading

Manikavelu VelayuthamRank #413 · 6K reputationPosted Nov 18, 2010, 9:13 PM EST
Let me know if you need any information on that.
Radu Ionascu7 reputationPosted Nov 18, 2010, 11:03 PM EST
infoProcess.StartInfo.Arguments = @"/nfo C:\test.nfo"; // is working
infoProcess.StartInfo.Arguments = @"/nfo " + Path.Combine(OutputFolder, Environment.MachineName + ".nfo");
// this is not working
Here OutputFolder is the path to Desktop\MyDir
Manikavelu VelayuthamRank #413 · 6K reputationPosted Nov 18, 2010, 11:23 PM EST
Just check in your c drive, whether its get saved like above.
Radu Ionascu7 reputationPosted Nov 18, 2010, 11:38 PM EST
How can I save it on Desktop?
Manikavelu VelayuthamRank #413 · 6K reputationPosted Nov 19, 2010, 12:04 AM EST
If your folder name contains any space like "Documents and Setting", its saving the file in the name of "Documents", that is the first part of the folder name.
Thats why its saving there.
If your folder name doesnt have any space, its storing correctly to that particular location.
Manikavelu VelayuthamRank #413 · 6K reputationPosted Nov 19, 2010, 12:17 AM EST
Radu Ionascu7 reputationPosted Nov 19, 2010, 12:26 AM EST
One solution would be :
save on c:\, then file.move to my dir on desktop. I'll give it a try ...
Thanks for u're posts.
Regards, Radu
Sam HobbsRank #107 · 20.5K reputationPosted Nov 19, 2010, 11:15 AM EST
Note that Quote is the double-quote character.