One of the overloads of the static Start() method that you have used,
accepts an instance of type ProcessStartInfo (System.Diagnostics). This
overload will allow you to pass command line arguments using the
ProcessStartInfo.Arguments property, which in your case will be the name of
the solution or project that you want to open, something like this...
ProcessStartInfo pInfo = new ProcessStartInfo("devenv.exe");
pInfo.Arguments = @"C:\Temp\MyProject.csproj";
Process.Start(pInfo);
Since, you are playing with the IDE, I would recommend you to have a look at
"Devenv Command Line Switches" title in MSDN documentation, which also lists
switches that will allow you to build and deploy your projects as well.
HTH... Metallikanz!
"puneet tripathi via .NET 247" <anonymous (AT) dotnet247 (DOT) com> wrote
Hello, i'm working in VC#. i've to open a new .NET Development environment
and new project window, from an existing application. I successfully opened
the New Development Environment using Process.Start("devenv.exe"); but now
how to open the new project window automatically, or what arguments to be
sent to display new project window.
--------------------------------
From: puneet tripathi
-----------------------
Posted by a user from .NET 247 (
http://www.dotnet247.com/)
<Id>1N5unnmKr0mb/ca3Wcbyog==</Id>