Groups | Blog | Home
all groups > dotnet clr > june 2006 >

dotnet clr : vc++: call an executable?


poojo hackma
6/28/2006 4:03:49 PM
Does anyone know how to call an executable from within Visual C++ 2005
Express (using the CLR)?

For example, click Button1 to launch Microsoft Paint:

System::Void Button1_Clicked(System::Object^ sender, System::EventArgs^
e)
{
// what can I use to open MS Paint?
}

Thanks.

Greg Young
6/28/2006 5:18:01 PM
Use the Start method on the System.Diagnostics.Process class ...
http://msdn2.microsoft.com/en-us/library/system.diagnostics.process.aspx

Cheers,

Greg Young
MVP - C#
http://codebetter.com/blogs/gregyoung

[quoted text, click to view]

AddThis Social Bookmark Button