2016-03-13 121 views
0

我必須指定一個文件路徑。我得到一個FileNotFoundException,但我不知道我的文件路徑有什麼問題。NetBeans找不到我的文件

這是它。它在bundle.properties文件中指定:

org_netbeans_modules_autoupdate_silentupdate_update_center=file:/Users/Jesper/Desktop/netbeans_site/updates.xml" 

例外:

INFO [org.netbeans.modules.autoupdate.updateprovider.DownloadListener]: Reading URL file:C:/Users/Jesper/Desktop/netbeans_site/updates.xml" failed (java.io.FileNotFoundException: C:\Users\Jesper\Desktop\netbeans_site\updates.xml" (Syntaksen i filnavnet, mappen eller diskenhedsnavnet er forkert)) 

最後部分的翻譯: 「語法的文件名,文件夾或diskunitname是錯誤的」。

我需要它找到的文件叫做「updates.xml」,位於我的桌面上一個名爲「netbeans_site」的文件夾中。

+0

引號請張貼整個代碼塊,使調用文件 – Dazak

+0

@Dazak它不是實際的一塊叫代碼,它只是一個在bundle.properties文件中指定的文件路徑。 – Jesper

+0

我想這可能是:或引號,或..也許NetBeans是採取相對路徑,嘗試把整個路徑(如c:/用戶/ jesper /桌面等等) – Dazak

回答

0

就像我發表的意見......問題是在路徑