Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
WindowsServerから、私は以下を使用しています:
File src = new File("\\\\servername\\D:\\LogFiles");
を確認するとsrc.isDirectory()、false と表示されます。別のディレクトリを試してみましたが、再度 false が返されます。チェックされ、ディレクトリは他の Windows Server に存在します。
src.isDirectory()
おそらく、問題はスラッシュにあるようです。誰か助けてくれませんか
問題のかなりの部分は、Windows 共有に "D:" コロンが含まれていないことです。D ドライブの管理共有にアクセスしようとしている場合は、"D$" を使用する必要があります。
これを試して:
File src = new File("\\\\servername\\D$\\LogFiles");