调试动态加载的程序集在Visual Studio .NET

编程入门 行业动态 更新时间:2024-10-28 01:23:39
本文介绍了调试动态加载的程序集在Visual Studio .NET的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我使用C#和反射来加载并调用从装配方法。我有大会本身的源代码。什么我需要做的就是调试器步入(不超过)动态加载的程序集的代码?

I am using C# and reflection to load and invoke methods from an assembly. I have the source code of the assembly itself. What do I need to do to get the debugger to step into (and not over) the code of the dynamically loaded assembly ?

如果我按在F11 ... .Invoke线就只有几步之遥了吧..

If I press F11 on the ....Invoke line it just steps over it ..

感谢

推荐答案

生成源本地动态加载的程序集,并确保您拥有的引用应用程序正在运行的PDB文件。

Build the source locally of dynamically loaded assembly and make sure you have the PDB files where the referencing app is running.

这是希望调试人民的共同要求ASP.NET MVC的源代码。有一些注意事项虽然关于GAC。

This is a common requirement for people wishing to debug the ASP.NET MVC source code. There are some caveats regarding the GAC though.

另一种快速的(但脏)的方式做的是暂时补充项目的动态加载的程序集到您的解决方案。这是史蒂夫·桑德森建议调试ASP.NET MVC框架。我个人比较喜欢PDB根。

Another quick (but dirty) way to do is to temporarily add the project for the dynamically loaded assembly to your solution. This is what Steve Sanderson recommends for debugging the ASP.NET MVC framework. Personally I prefer the PDB root.

更多推荐

调试动态加载的程序集在Visual Studio .NET

本文发布于:2023-11-13 09:37:03,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1584022.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:加载   程序   动态   NET   Studio

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!