System.Diagnostics.Debug.WriteLine

Discussion in 'ASP .Net' started by A.M, Apr 13, 2004.

  1. A.M

    A.M Guest

    Hi,

    If I use System.Diagnostics.Debug.WriteLine in a asp.net application, where
    does the output go?
    Is there any trace monitor application thar shows me the trace output?

    Thanks,
    Allan
    A.M, Apr 13, 2004
    #1
    1. Advertising

  2. A.M

    TE Guest

    Hello,

    maybe check SysInternals - they have a tool to display
    debug infos of applications.
    otherwise check TraceHandlers.

    regards

    tom

    >-----Original Message-----
    >Hi,
    >
    >If I use System.Diagnostics.Debug.WriteLine in a

    asp.net application, where
    >does the output go?
    >Is there any trace monitor application thar shows me the

    trace output?
    >
    >Thanks,
    >Allan
    >
    >
    >.
    >
    TE, Apr 14, 2004
    #2
    1. Advertising

  3. Hi Allan,

    From your description, you're wondering where does the output from the
    System.Diagnostics.Debug.
    WriteLine go ?

    As far as I know, the System.Diagnostics.Debug has a property called
    "Listeners"which mantain the collection of listeners that is monitoring the
    debug output. By default, there is a default listner "DefaultTraceListener"
    in the collection. We can define our custom Listeners which derived from
    the "TraceListener" Abstract class and add their instances into the
    Debug.Listeners collection so that we can redirect the Ouput to whatever we
    want. For detailed info you may view the following reference in MSDN:

    #Debug.Listeners Property
    http://msdn.microsoft.com/library/en-us/cpref/html/frlrfSystemDiagnosticsDeb
    ugClassListenersTopic.asp?frame=true

    In addition, in ASP.NET, you may also use the "Trace" feature which can
    also log many trace info. You can use Trace.Write .. method within code
    line to log some infos and which can be view in page level or application
    level. For detailed on Trace, here are some reference in MSDN:

    #ASP.NET Trace
    http://msdn.microsoft.com/library/en-us/cpguide/html/cpcontracefunctionality
    ..asp?frame=true

    Regards,

    Steven Cheng
    Microsoft Online Support

    Get Secure! www.microsoft.com/security
    (This posting is provided "AS IS", with no warranties, and confers no
    rights.)

    Get Preview at ASP.NET whidbey
    http://msdn.microsoft.com/asp.net/whidbey/default.aspx
    Steven Cheng[MSFT], Apr 14, 2004
    #3
  4. Hi Allan,

    Have you had a chance to check out the suggestions in my last reply or have
    you got any further ideas on this issue? If you have anything unclear or if
    there're anything else we can help, please feel free to post here. Thanks.

    Regards,

    Steven Cheng
    Microsoft Online Support

    Get Secure! www.microsoft.com/security
    (This posting is provided "AS IS", with no warranties, and confers no
    rights.)

    Get Preview at ASP.NET whidbey
    http://msdn.microsoft.com/asp.net/whidbey/default.aspx
    Steven Cheng[MSFT], Apr 16, 2004
    #4
  5. A.M

    A.M Guest

    Thank you for follow-up.

    I checked resources you refered me. They are helpfull.

    I was expectiong that I could find a 3rd party debug listenner to record all
    debug outputs. It seems that there is not any. mybe it is not quite usefull
    in practical world.

    Thanks,
    Ali




    "Steven Cheng[MSFT]" <> wrote in message
    news:...
    > Hi Allan,
    >
    > Have you had a chance to check out the suggestions in my last reply or

    have
    > you got any further ideas on this issue? If you have anything unclear or

    if
    > there're anything else we can help, please feel free to post here. Thanks.
    >
    > Regards,
    >
    > Steven Cheng
    > Microsoft Online Support
    >
    > Get Secure! www.microsoft.com/security
    > (This posting is provided "AS IS", with no warranties, and confers no
    > rights.)
    >
    > Get Preview at ASP.NET whidbey
    > http://msdn.microsoft.com/asp.net/whidbey/default.aspx
    >
    >
    A.M, Apr 19, 2004
    #5
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. S.K. Dutta
    Replies:
    2
    Views:
    1,894
    Yan-Hong Huang[MSFT]
    Jul 30, 2003
  2. arc
    Replies:
    1
    Views:
    589
    Ken Cox [Microsoft MVP]
    Aug 21, 2003
  3. Replies:
    1
    Views:
    526
    john_teague
    Sep 1, 2005
  4. Replies:
    1
    Views:
    1,126
    Mike Placentra II
    Oct 14, 2007
  5. Max2006
    Replies:
    1
    Views:
    2,040
    Steven Cheng [MSFT]
    Jun 25, 2008
Loading...

Share This Page