468,283 Members | 2,005 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,283 developers. It's quick & easy.

Launching one c# application from another


Excuse the novice aspects of this question, but:

What techniques are available to me for launching one c# application (
console .exe) from another?

For example, I know there is the Process and ProcessInfo classes, but
these seem designed for launching non-CLR applications.

Should I access the .exe as a reference?

Or dynamically invoke it, or just invoke its methods?

Should I use Reflection?

Is there a way to "launch" it so that once its running, it's entirely
detached from the calling application?

Is that what Reflection.Emit is for?

Is there a proper way to load a new Application space for a second
application, and is this the way to do what I am asking?

Can you direct me to any good references on the topic...I've been
Googling all weekend and everything seems to talk about launching a DOS
application (using Process) not about a c# app launching another c#?
--
RSS Feed/Incognito Blog
http://blog.360.yahoo.com/rss-siXzkM...bTlKkOL5SWLA--
Jan 16 '06 #1
1 1829

Maybe this answers my question, or part of it(?):

http://msdn.microsoft.com/library/de...emblyTopic.asp
class Test {
public static void Main() {
AppDomain currentDomain = AppDomain.CurrentDomain;
AppDomain otherDomain = AppDomain.CreateDomain("otherDomain");

currentDomain.ExecuteAssembly("MyExecutable.exe");
// Prints "MyExecutable running on [default]"

otherDomain.ExecuteAssembly("MyExecutable.exe");
// Prints "MyExecutable running on otherDomain"
}
}
John A. Bailo wrote:

Excuse the novice aspects of this question, but:

What techniques are available to me for launching one c# application (
console .exe) from another?

For example, I know there is the Process and ProcessInfo classes, but
these seem designed for launching non-CLR applications.

Should I access the .exe as a reference?

Or dynamically invoke it, or just invoke its methods?

Should I use Reflection?

Is there a way to "launch" it so that once its running, it's entirely
detached from the calling application?

Is that what Reflection.Emit is for?

Is there a proper way to load a new Application space for a second
application, and is this the way to do what I am asking?

Can you direct me to any good references on the topic...I've been
Googling all weekend and everything seems to talk about launching a DOS
application (using Process) not about a c# app launching another c#?

--
RSS Feed/Incognito Blog
http://blog.360.yahoo.com/rss-siXzkM...bTlKkOL5SWLA--
Jan 17 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Metnetsky | last post: by
3 posts views Thread by Brad Jones | last post: by
6 posts views Thread by sebastien | last post: by
1 post views Thread by Water Cooler v2 | last post: by
2 posts views Thread by MrBee | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.