PC Review


Reply
Thread Tools Rate Thread

Debugging two processes question/launching two debug processes

 
 
=?Utf-8?B?bTExNTMz?=
Guest
Posts: n/a
 
      4th Nov 2004
I am writing a fairly complex application in c# and Visual Studio .Net 2003.
Right now I am working on a simple console application (to be launched in the
future from a service) that receives messages sent via IP from an external
device. I am also writing a simulator of that external device.

My question: How do I setup the Visual Studio so that when I start debugging
my c# application, both my message sink AND simulator are launched?

I have both applications setup as projects within a single solution, and
have been manually launching both via the right mouse button menu and the
debug/start new instance selections... I remember being able to do this in VS
6.0, so it just has to be possible... I just can't come up with the right
search to find how.

Thanks for your help,
Marc
 
Reply With Quote
 
 
 
 
Rafael Pereyra
Guest
Posts: n/a
 
      4th Nov 2004
Use

System.Diagnostic.Debugger.Break() to open an instance of Visual Studio as a
debugger.

Good Luck!

Rafael.


"m11533" <(E-Mail Removed)> wrote in message
news:FB8CCE2A-0D00-49BA-8C5F-(E-Mail Removed)...
>I am writing a fairly complex application in c# and Visual Studio .Net
>2003.
> Right now I am working on a simple console application (to be launched in
> the
> future from a service) that receives messages sent via IP from an external
> device. I am also writing a simulator of that external device.
>
> My question: How do I setup the Visual Studio so that when I start
> debugging
> my c# application, both my message sink AND simulator are launched?
>
> I have both applications setup as projects within a single solution, and
> have been manually launching both via the right mouse button menu and the
> debug/start new instance selections... I remember being able to do this in
> VS
> 6.0, so it just has to be possible... I just can't come up with the right
> search to find how.
>
> Thanks for your help,
> Marc



 
Reply With Quote
 
=?Utf-8?B?bTExNTMz?=
Guest
Posts: n/a
 
      4th Nov 2004
I don't completely follow your suggestion? Are you saying I need to put this
call in my code? Does it go into my simulator or server? I just remember a
project property in VS 6 that let me have it execute a different program in
addition to the current executable.

Thanks again for your help,
Marc

"Rafael Pereyra" wrote:

> Use
>
> System.Diagnostic.Debugger.Break() to open an instance of Visual Studio as a
> debugger.
>


 
Reply With Quote
 
Rafael Pereyra
Guest
Posts: n/a
 
      4th Nov 2004
Sorry, I was busy and made a very short reply...

Yes if you put that line in your code (C# i don't know the sintax in VB.NET
however I think is the same) at the beginning or wherever you want to debug
your program.

Use the debug version of your program, at that point the program invokes a
debugger (all debuggers installed in your system AFAK). Simply choose a new
instance of Visual Studio and there you go...

A new instance of Visual Studio will popup and inmediatelly attaches to your
process using the debug information available.

Good Luck.
Rafael.


"m11533" <(E-Mail Removed)> wrote in message
news:30B9168D-E830-4613-B9AD-(E-Mail Removed)...
>I don't completely follow your suggestion? Are you saying I need to put
>this
> call in my code? Does it go into my simulator or server? I just remember a
> project property in VS 6 that let me have it execute a different program
> in
> addition to the current executable.
>
> Thanks again for your help,
> Marc
>
> "Rafael Pereyra" wrote:
>
>> Use
>>
>> System.Diagnostic.Debugger.Break() to open an instance of Visual Studio
>> as a
>> debugger.
>>

>



 
Reply With Quote
 
Bonj
Guest
Posts: n/a
 
      4th Nov 2004
Debug the service by attaching to process ('Debug' -> 'Processes') and then
IIRC there's an option to debug child processes also. You could give that a
bash.

"m11533" <(E-Mail Removed)> wrote in message
news:FB8CCE2A-0D00-49BA-8C5F-(E-Mail Removed)...
>I am writing a fairly complex application in c# and Visual Studio .Net
>2003.
> Right now I am working on a simple console application (to be launched in
> the
> future from a service) that receives messages sent via IP from an external
> device. I am also writing a simulator of that external device.
>
> My question: How do I setup the Visual Studio so that when I start
> debugging
> my c# application, both my message sink AND simulator are launched?
>
> I have both applications setup as projects within a single solution, and
> have been manually launching both via the right mouse button menu and the
> debug/start new instance selections... I remember being able to do this in
> VS
> 6.0, so it just has to be possible... I just can't come up with the right
> search to find how.
>
> Thanks for your help,
> Marc



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Weird issue when launching processes. MacScotsman Microsoft VC .NET 0 2nd Nov 2010 02:07 PM
how to debug shell execution processes? Wilfried Microsoft Windows 2000 CMD Promt 4 20th Nov 2009 10:15 PM
Debugging two processes at the same time Reid Roman Microsoft Dot NET 4 25th Aug 2005 03:43 PM
Debugging COM+ Processes Francois Guerin Microsoft Dot NET 4 26th Nov 2003 11:47 AM
Launching Internet Explorer in differnet windows (processes) Nick Litchfield Windows XP Internet Explorer 1 2nd Jul 2003 12:58 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:49 PM.