2010-06-02 56 views
3

我遇到了一個問題,即進入IIS7上託管的代碼。無法自動進入服務器。無法調試遠程過程

基本上我有一個測試類調用像這樣

ISecurityService service = new SecurityServiceClient(); 
MembershipUser membershipUser = null; 
membershipUser = service.GetMembershipUser("Mark"); // THIS LINE FAILS!!! 

我碰到下面的錯誤,但我擁有一切啓用,據我所知WCF服務,即

<compilation debug="true" targetFramework="4.0" /> 

這裏是錯誤味精,我會讚賞任何反饋。如果我不嘗試進入上面的行,那麼一切正常。


微軟的Visual Studio

無法自動步入服務器。遠程過程無法調試。這通常表示調試尚未在服務器上啓用。請參閱幫助瞭解更多信息。

回答

0

你是否在使用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

希望它有助於

編輯:這裏有一個外觀以及 Return MembershipUser using WCF service

+0

其實我使用的是Windows 7,如果我做的是F5,它可以正常工作......當我嘗試從我的班級圖書館進入我的wcf服務器(託管在IIS中)時,我的測試是 – 2010-06-02 14:37:40

1

不要忘記設置編譯調試=「真」在你的wcf服務web.config文件中。

+3

他在此專門說過問題他補充說已經.. – Ghlouw 2012-03-12 09:11:41

0

我有過同樣的錯誤。問題在於IIS上的WCF Web服務站點已停止,因爲另一個進程佔用了相同的端口!

要發現什麼樣的流程,從命令提示符:

netstat -aon | find ":your_iis_web_services_port_number" 

希望這有助於你。

0

您也可以嘗試在IIS中啓用匿名身份驗證。當我遇到這個問題時,這對我有用。

0

dont forget to set compilation debug="true" in your wcf service web.config file.

如果從WCF服務,是有問題,你有start wcf service host when debugging another project in the same solution檢查不同的啓動項目,您將需要設置在compilation debug="true"項目的App.config。