gpt4 book ai didi

file - java.io.FileNotFoundException : "C:/Users/Joe/Desktop/file.txt" (The filename, 目录名,或者卷标语法不正确)

转载 作者:行者123 更新时间:2023-12-04 21:17:02 25 4
gpt4 key购买 nike

我有这个代码:

BufferedReader in = new BufferedReader
(new InputStreamReader(System.in));
System.out.print("Public Key to encrypt with: ");
String publicKeyFilename = in.readLine();
FileInputStream fis = new FileInputStream(publicKeyFilename);

当我输入文件“C:/Users/Joe/Desktop/file.txt”的目的地时,结果是这个错误:

java.io.FileNotFoundException: "C:/Users/Joe/Desktop/file.txt" (The filename, directory name, or volume label syntax is incorrect)



但是文件存在,我该怎么办?

感谢你..

最佳答案

when i enter the destination of the file "C:/Users/Joe/Desktop/file.txt"



提供的文件名应不带引号 ("")

关于file - java.io.FileNotFoundException : "C:/Users/Joe/Desktop/file.txt" (The filename, 目录名,或者卷标语法不正确),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20585240/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com