2012-02-23 88 views
0

我在Azure中創建了一個使用WCF服務的解決方案。我的問題是我無法添加服務引用。它給我的錯誤:從地址下載元數據時出錯。請驗證您是否輸入了有效地址

There was an error downloading metadata from the address. Please verify that you have entered a valid address.

爲什麼我得到這個錯誤?

+0

@Wingu你有任何soln? – 2012-03-21 12:30:50

+0

@Shankar,我的問題是由於重命名wcf導致的。這一切我都做到了讓它再次運作。 (FileName GenericService.Svc)original; 「<%@ ServiceHost Language =」VB「Debug =」true「Service =」GenericService.Service1「CodeBehind =」ServiceGeneric.svc.vb「%>」 我改變了它; 「<%@ ServiceHost Language =」VB「Debug =」true「Service =」GenericService.ServiceGeneric「CodeBehind =」ServiceGeneric.svc.vb「%>」 – 2012-03-22 06:21:29

回答

1

我知道我遲到了,但是從未來編人着想,這裏是我們到目前爲止想通了......

如果你想找到確切的錯誤被拋出,可以將includeExceptionDetailInFaults設置爲true。

在服務的web.config:

<!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information --> 
     <serviceDebug includeExceptionDetailInFaults="true"/> 

注:這不會解決問題,反而會讓你知道到底是什麼原因造成的。

另一個說明:我偷了xkcd的開場白。