无法自动进入服务器。远程程序无法调试
我在进入 IIS7 上托管的网站代码时遇到问题。
基本上我有一个调用 WCF 服务的测试类,所以
ISecurityService service = new SecurityServiceClient();
MembershipUser membershipUser = null;
membershipUser = service.GetMembershipUser("Mark"); // THIS LINE FAILS!!!
我收到以下错误,但据我所知,我已启用所有功能,即
<compilation debug="true" targetFramework="4.0" />
这是错误消息,我将不胜感激任何反馈。如果我不尝试进入上面的行,那么一切正常。
<小时>微软视觉工作室
无法自动单步进入服务器。无法调试远程过程。这通常表明服务器上尚未启用调试。请参阅帮助以获取更多信息。
I am having a problem stepping into code which is a website hosted on IIS7.
Basically I have a test class which calls a WCF service like so
ISecurityService service = new SecurityServiceClient();
MembershipUser membershipUser = null;
membershipUser = service.GetMembershipUser("Mark"); // THIS LINE FAILS!!!
I get the following error but I have everything enabled as far as I know, i.e.
<compilation debug="true" targetFramework="4.0" />
Here is the error msg, I would appreciated any feedback. If I don't try and step into the line above then all works ok.
Microsoft Visual Studio
Unable to automatically step into the server. The remote procedure could not be debugged. This usually indicates that debugging has not been enabled on the server. See help for more information.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
不要忘记在 wcf 服务 web.config 文件中设置编译 debug="true"。
dont forget to set compilation debug="true" in your wcf service web.config file.
你用的是vista吗?
不管怎样,看看这篇文章:
http://mvolo.com/blogs/serverside/archive/2006/12/28/Fix-problems-with-Visual-Studio-F5-debugging-of-ASP。 NET-applications-on-IIS7-Vista.aspx
希望它有帮助
编辑:也看看这里
使用 WCF 服务返回 MembershipUser
are you using vista by any chance?
anyways, take a look at this post:
http://mvolo.com/blogs/serverside/archive/2006/12/28/Fix-problems-with-Visual-Studio-F5-debugging-of-ASP.NET-applications-on-IIS7-Vista.aspx
hope it helps
EDIT: have a look here as well
Return MembershipUser using WCF service
您还可以尝试在 IIS 中打开匿名身份验证。当我遇到这个问题时,这对我有用。
You can also try turning on anonymous authentication in IIS. That worked for me when I encountered this issue.
我也有同样的错误。问题是 IIS 上的 WCF Web 服务站点已停止,因为另一个进程正在占用同一端口!
要了解进程是什么,请从命令提示符处:
希望这对您有帮助。
I've had the same error. The problem was that the WCF web service's site on IIS was stopped, because another process was occupying the same port!
To discover what process is, from the command prompt:
Hope this help you.
不要忘记在 WCF 服务 web.config 文件中设置编译 debug="true"。
如果您的启动项目与有问题的 WCF 服务不同,并且您
在以下情况下启动 WCF 服务主机调试同一解决方案中的另一个项目
检查后,您需要在该项目的App.config中设置compilation debug="true"
。dont forget to set compilation debug="true" in your wcf service web.config file.
If your startup project different from the WCF Service that is in question and you have
start wcf service host when debugging another project in the same solution
checked, you will need to setcompilation debug="true"
in that projects App.config.