IntelliTrace 历史调试不会在 Click-EventHandler 中跳转 [英] IntelliTrace Historical Debugging does not jump in Click-EventHandler

查看:16
本文介绍了IntelliTrace 历史调试不会在 Click-EventHandler 中跳转的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个带有一个按钮和一个标签的小型 WPF 应用程序.Button 的 Click-Eventhandler do

I have created a small WPF-Application with one Button and a Label. The Click-Eventhandler of the Button do

private void Button_Click(object sender, RoutedEventArgs e) {
    var s = this.Height;
    this.lbl.Content = s;
} 

我已激活 IntelliTrace 事件收集.当我运行调试并单击按钮时,我会在 IntelliTrace-Event-List 中看到相应的事件:

I have activated IntelliTrace Event collecting. When I run debug and click on the Button, I see in the IntelliTrace-Event-List the corresponding events:

当我单击激活历史调试"时,Visual Studio 显示以下内容:

When I click on "Activate Historical Debugging" Visual Studio shows the following:

和这个 StackTrace:

and this StackTrace:

为什么我现在不能跳转到 EventHandler Button_Click()?

Why can I not jump to the EventHandler Button_Click() now?

推荐答案

(1) 请在 TOOLS->Options->Debugging->Symbols 下启用 Microsoft 符号服务器.

(1) Please enable the Microsoft symbol servers under TOOLS->Options->Debugging->Symbols.

(2) 在 TOOLS->Options->Debugging 下勾选Enable .NET Framework source stepping"和Enable source serve support".

(2) Check "Enable .NET Framework source stepping" and "Enable source serve support" under TOOLS->Options->Debugging.

(3) 在你的项目属性->Debug下,禁用启用Visual Studio托管进程"选项,启用启用本机代码调试"选项.

(3) Under your project properties->Debug, disable the option "Enable the Visual Studio hosting process", and enable the option "Enable native code debugging".

然后使用断点调试您的应用程序,查看结果.

And then debug your app with breakpoint, view the result.

更新:

intellitrace 日志中的按钮点击事件并不是你想象的那样.它不是在跟踪您的代码,而是在跟踪表示框架.Intellitrace 对事件处理程序一无所知.

The button click event in the intellitrace log is not what you thinks it is. It’s not tracing your code, it’s tracing the presentation framework. Intellitrace knows nothing about the event handler.

但是,您可以通过在事件处理程序中使用跟踪点来实现您想要的.

However, you can achieve what you wants by using a tracepoint in your event handler.

这篇关于IntelliTrace 历史调试不会在 Click-EventHandler 中跳转的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆