filenotfoundexception

    1熱度

    1回答

    啓動一個單元測試時出現此類錯誤: 測試方法TestName拋出異常: System.IO.FileNotFoundException:無法加載文件或程序集'Assembly.dll '或它的一個依賴關係。找到指定的模塊不能爲 。 僅當使用vstest.console.exe時纔會出現此問題。當我通過Visual Studio運行我的測試時,不會發生這種情況(2013)。我知道當通過Visual S

    0熱度

    1回答

    所以我必須使用終端運行程序。但是當我這樣做時,它告訴我我找不到要使用的文件。當我使用NetBeans運行我的程序時,沒有任何問題。 這個id我的代碼 File file = new File("src/level/Level2.txt"); FileReader fileReader = new FileReader(file); BufferedReader reader =

    0熱度

    1回答

    我有一些問題讓我的項目工作的可執行jar文件(在Eclipse IDE之外)。我想通了這個問題與Java的罐子fileName.jar 下面的代碼: fileIn = new Scanner(new File("src//resources//TestSave.txt")); 通過一個小故障診斷和研究,我明白,這不是在可執行的JAR工作,因爲它不有一個src文件夾,只能在IDE中創建。這裏是我

    1熱度

    1回答

    爲什麼我可以在PowerShell上執行以下代碼,而不是在同一臺計算機上的PowerShell(x86)上執行以下代碼? Get-WmiObject -Namespace "root\Microsoft\SqlServer\ComputerManagement13" -Class ServerSettingsGeneralFlag -Filter "FlagName='ForceEncryptio

    0熱度

    1回答

    C:\用戶\ sunka \桌面\ CS DEPT \秋季2k16 \信息結構>罐子 -xvf week2.zip java.io.FileNotFoundException: week2.zip (The system cannot find the file specified) at java.io.FileInputStream.open0(Native Method)

    2熱度

    2回答

    時,遇到了java.io.FileNotFoundException我有以下代碼: VideoView videoView = (VideoView)findViewById(R.id.instructionsvideo); assert videoView != null; videoView.setVideoPath("android.resource://" + getP

    0熱度

    1回答

    我在我的項目(Player.xml)的根目錄下創建了一個xml文件。我在AndroidManifest.xml中添加了使用權限標籤。我覺得我已經嘗試了一切,仍然得到FileNotFoundException。 我在onCreate()方法的代碼: try { String newFile = "/TTBossUI/Player.xml"; FileInputStream i

    1熱度

    3回答

    我編寫了一個java程序,其中必須呈現ftl並在String變量中獲取輸出。 請在下面找到我的代碼: Configuration cfg = new Configuration(); StringWriter stringWriter = new StringWriter(); try { Template template = cfg.getTemplate("src/resp

    0熱度

    3回答

    我正在研究一個簡單的應用程序,並試圖瞭解如何使用json解析器從json文件中讀取數據。我寫了一個簡單的json文件並將其放入我的一個目錄中。然後我用正確的時鐘來獲取路徑,並寫了下面的代碼: java.io.FileNotFoundException: C:\Users\My Name\IntelliJIDEAProjects\Intereview\app\src\main\res\Data\da

    0熱度

    2回答

    我寫了一些代碼拍攝照片並將其保存在外部存儲器中。如果我運行該應用程序,並使圖片,我得到文件未找到例外。 這裏是我的代碼: public class CameraActivity extends BaseActivity { //variables for navigation drawer private String[] navMenuTitles; privat