locked
Debugging a Windows Store App using Trace

    Question

  • I am trying to figure out how to get my debug output to go to a text file instead of the Output window by using the Trace class and TraceListeners. However, I am having trouble getting Visual Studio 2013 to let me use the Trace class. When I looked at the documentation for the Trace class at

    http://msdn.microsoft.com/en-us/library/system.diagnostics.trace(v=vs.110).aspx

    The methods and properties did not have the icon for Windows Store next to them, which makes me wonder if I will just have to deal with not using Trace. Is there a way to use Trace or output the debugging information to a file when debugging a Windows Store app? Thanks.


    Nathan Sokalski njsokalski@hotmail.com http://www.nathansokalski.com/

    Saturday, July 05, 2014 11:26 PM

Answers

  • Hi Nathan,

    Trace is not supported in Windows Store App, but you can use some third party stuff instead, for instance I found this one by searching: https://github.com/mbrit/metrolog

    Also use Debug should work as same as Trace, you can write debug information to the file if necessary.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Monday, July 07, 2014 8:26 AM
    Moderator