System.Diagnostics.Debug

  • Thread starter Thread starter Mike
  • Start date Start date
M

Mike

In my Smart Device Project, I'm trying to show a message only when
debugging. We used to be able to do this with Debug.Print in VB 6. I've
tried System.Diagnostics.Debug.WriteLine and this doesn't seem to do
anything - I can't see it writing anywhere.

I also tried Debug.Assert and Debug.Fail and both of these do show the
message on the Pocket PC device, but then when I click on Continue or Debug
at the bottom of the message on the device, I get a NullReferenceException
in Visual Studio.

Can someone explain what is going on here?
 
Hi,

Debug.writeline will send it output to the ide's output window
when the application in running in debug mode.

Ken
 
Hi Mike,

The initial release of the Visual Studio.NET debugger for the .NET Compact
Framework does not implement this feature. However, you can define your own
listener classes within your application to handle the debug messages.

Jimmy Zhu
 
Back
Top