Above is the pic of the error and my code. Whenever I try to show the image, Access is denied. May I know how can I fix this problem? I have installed PIL and imported simpleImage. It was ok before when I tried a month ago.
Asked
Active
Viewed 287 times
-1
-
are you on windows 10? edit: Oh I just opened screenshot and I see that you are using windows – Andrew Clark May 28 '21 at 14:48
-
Yes, I am on windows 10. Sorry, I should've mentioned it in the caption. – Sue May 28 '21 at 15:09
1 Answers
-1
Close PyCharm. Right click PyCharm, open as Administrator.
Edit1:
If that doesn't work, try the following steps-> Open file explorer. Go to the folder, or folders, you wish to write in. Right-Click on it. Select Properties. In the properties window select the security tab. Click Edit and edit it as you wish or need to give access to programs or users.

Andrew Clark
- 850
- 7
- 13
-
Thanks a lot, the first one works. I tried the second way, no matter how many times I changed my permission, it's still said "access is denied" ! – Sue May 28 '21 at 15:13
-
Awesome, I'm glad this worked for you. If you mark the answer correct, it will help others in the future know this is a valid solution. Cheers – Andrew Clark May 28 '21 at 15:16
-
oh sure, I will do it. I am new here so there's still a lot of things I'm unfamiliar with. Thanks for telling! – Sue May 28 '21 at 15:17
-