Supporting two executables in a solution

M

Morris

I use VS2008 and I need a solution that contains 2 executables (two
different processes) of which one should launch the other.
1. Does C# support such launching(with some paramters) an how?
2. Does VS2008 suport that-should I simply add the other excutables as I
would do with ordinary dll?
Thanks in advance
Morris
 
P

Peter Duniho

Morris said:
I use VS2008 and I need a solution that contains 2 executables (two
different processes) of which one should launch the other.
1. Does C# support such launching(with some paramters) an how?

..NET does, yes. See Stefan's reply for the link to the docs for the
Process class.
2. Does VS2008 suport that-should I simply add the other excutables as I
would do with ordinary dll?

There's no need to add the dynamically launched EXE as a reference, nor
would doing so help. For the Process class, you'll need the EXE to
exist as a file at a known location (e.g. in the same directory with the
main program), and pass that file path to the Process class.

Pete
 
M

Morris

There's no need to add the dynamically launched EXE as a reference, nor
would doing so help. For the Process class, you'll need the EXE to exist
as a file at a known location (e.g. in the same directory with the main
program), and pass that file path to the Process class.

Pete
Dear Pete,
Though there is no need I still think that it may be convinient to add it
because I may need to modify the second executable along the solution
development life time, as would be with any dll in the solution.
Is it posible?
Regards
Morris
 
P

Peter Duniho

Morris said:
Though there is no need I still think that it may be convinient to add it
because I may need to modify the second executable along the solution
development life time, as would be with any dll in the solution.
Is it posible?

I don't understand that part of the question. You can add an EXE as a
reference, just as you can a DLL. But unless you're actually using the
contents of the EXE directly in your own code (e.g. using a class found
in there, reading a resource, etc.) what would the point be?

Pete
 
C

Chris Dunaway

Dear Pete,
Though there is no need I still think that it may be convinient to add it
because I may need to modify the second executable along the solution
development life time, as would be with any dll in the solution.
Is it posible?
Regards
Morris

You can have both projects in the same solution, if that's what you
mean.

Chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top