无法在Windows应用商店应用中使用Trace.WriteLine

Ale*_*x F 7 c# trace windows-8 windows-store-apps

在Windows应用商店应用中,我可以使用:

System.Diagnostics.Debug.WriteLine("Test");
Run Code Online (Sandbox Code Playgroud)

但更换Debug同Trace提供了以下错误:CS0103: The name 'Trace' does not exist in the current context我怎样才能解决这个问题?

vcs*_*nes 10

WinRT没有Trace,它缺少跟踪侦听器.Debug.WriteLine如果不诉诸像metrolog这样的第三方,你就能做到最好.