java.io.FileNotFoundException: (Access is denied)

前端 未结 4 1590
暗喜
暗喜 2020-11-27 06:35

I am trying to read the files inside a folder, but when I run the program it throws this exception. I tried with some other folders also. It throws the same exception.

4条回答
  •  北海茫月
    2020-11-27 06:56

    1. check the rsp's reply
    2. check that you have permissions to read the file
    3. check whether the file is not locked by other application. It is relevant mostly if you are on windows. for example I think that you can get the exception if you are trying to read the file while it is opened in notepad

提交回复
热议问题