调试silverlight应用程序问题 [英] Debugging silverlight application problem

查看:163
本文介绍了调试silverlight应用程序问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的VS2010不会停止在silverlight应用程序内的断点。调试过程中似乎没有加载符号。当我将鼠标悬停在断点上时,它说目前不会受到伤害,没有符号被加载。



我已尝试过谷歌提供的所有可能的解决方案并没有成功。即使我创建了由ASP .NET Web项目托管的全新Silverlight应用程序,也会出现此问题。我的所有项目配置看起来都很好 - 在Web项目中启用了silverlight调试。



我正在使用silverlight 4.
这里是一个链接到从tepmlate创建的示例项目



任何想法?



PS我刚刚尝试重新安装VS2010,问题依然存在。



编辑:我刚刚在另一台机器上测试了同一个项目,它在断点处停止,问题出在VS或silverlight的配置中。



与Matt Dotson的帮助我设法手动附加调试器。但是这个解决方案对于日常使用是不够的。

解决方案

根据我在Silverlight中的经验,按照这些步骤, gable。



条件1>



首先我们需要确保在Web Project的属性中有一个Web部分,如下所示,必须检查Silverlight复选框。





条件2>
按菜单调试=>附加调试器>



Visual Studio有时无法附加调试平台,您需要引导方式:)。通过这种方式,您可以调试其他平台(也可以调试您的产品平台,但pdb文件必须同步,不要忘记您可能会暂停使用此产品平台)。





条件3 >您的默认网络浏览器可能是Firefox,Chrome或IE。除了Visual Studio默认尝试附加到IE。但是当您运行VS调用默认浏览器时,您需要在条件2中使用手动附件,或者右键单击默认页面>浏览。





条件4>有xap文件通常位于web project\ClientBin目录下。有时在构建操作后,此文件无法替换,并且您的ProjectDll和您的Project PDB文件不会同步。这导致错误的行匹配调试或找不到调试文件附加警告。我强烈建议删除Bus项目中的所有生成的文件,并删除Clientbin\ProjectName.xap文件。重建后,一切都可以!





希望有帮助。


My VS2010 doesn't stop at breakpoints inside of silverlight application. It appears that no symbols for it have been loaded during debugging. When I hover over the break point it says "The braekpoint will not currently be hit, no symbols have been loaded".

I have tried all of possible solutions offered by google and have no success. The problem occurs even when I create brand new silverlight app hosted by an ASP .NET web project. All of my project configuration looks fine - silverlight debugging is enabled in the Web project.

I am using silverlight 4. here a link to the sample project created out from the tepmlate.

Any thoughts ?

P.S I just tried to reinstall VS2010 and the problem still exists.

EDIT: I just tested the same project on another machine and it stops at the break point it seams that the problem is somewhere in the configuration of VS or silverlight.

with Matt Dotson's help I managed to attach the debugger manually. However this solution is not good enough for daily use.

解决方案

Depending on my experience in Silverlight following these steps keep your project debug-gable.

Condition 1>

Firstly we need to be ensure that in Web Project's properties there is a Web section, as you see below Silverlight checkbox must be checked.

Condition 2> Follow In Menu Debug => Attach Debugger>

Visual Studio sometimes can't attach debugging platform you need to lead the way :) . By this way you may debug other platforms,(also you may debug your product platform but pdb files must be sync and don't forget you may suspend your product platform using this).

Condition 3> Your default web browser may be Firefox,Chrome or other than IE.By Visual Studio default try to attach to IE. But when you run VS calls default browser,so you need to have a manual attachment in Condition 2 or set your default browser by right clicking on default page > Browse with .

Condition 4> There is xap file generally located in web project\ClientBin directory. Sometimes after build operations this file can't be replaced and your ProjectDll and your Project PDB files not be sync. This cause wrong line match while debugging or can't find a debugging file attached caution. I strongly suggest delete all generated files in Bus project and delete Clientbin\ProjectName.xap file. After rebuild all it must be ok!

Hope helps.

这篇关于调试silverlight应用程序问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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