2013-01-31 80 views
1

我發現了以下情況例外,當我嘗試安裝ClickOnce應用程序:ClickOnce部署中出現「無法找到網絡名稱」異常?

Below is a summary of the errors, details of these errors are listed later in the log. 
* Activation of C:\Users\user\Downloads\appname.application resulted in exception. Following failure messages were detected: 
    + Downloading file://192.168.2.9/appdir/appname.application did not succeed. 
    + The network name cannot be found. 

    + The network name cannot be found. 

    + The network name cannot be found. 

我一直沒能弄明白。我試過在網上尋找,似乎沒有任何資源問題。有人知道如何解決這個問題嗎?

+0

這是您家庭網絡中的文件..?如果是的話,你試圖下載文件的機器的名字是什麼?它可能也有助於顯示代碼,你得到這個錯誤..如果這是一個在你的局域網上的文件,那麼爲什麼不使用正常的File.Copy方法..' – MethodMan

+0

@DJKRAZE沒有代碼, ClickOnce啓動程序拋出異常。我試過使用主機名和IP。 – Daniel

+0

誰擁有或擁有.msi的源代碼..你寫過嗎..? – MethodMan

回答

2

原來這是發佈設置中安裝URL的問題。我沒有使用網絡路徑,而是使用共享路徑。實際位置是在IIS中設置的,所以當然在共享中找不到該文件。

從改變場 「安裝文件夾URL」:

\\\server-name\path

http://server-name/path

解決了這個問題。愚蠢的錯誤。

0

我以這種方式解決了這個問題。檢查的權限在IIS都和文件夾

Give the IIS Full control Permision to Everyone 
Share the physical path folder to Everyone 
0

天色這些類型的錯誤信息是由於無法通過網絡找到錯誤的連接字符串。重新檢查連接字符串中的數據源值或服務器值和數據庫名稱將解決問題

相關問題