Author Topic: Permission Denied ; Code-Blocks making files read only  (Read 13588 times)

Offline obidan

  • Single posting newcomer
  • *
  • Posts: 4
Permission Denied ; Code-Blocks making files read only
« on: April 13, 2012, 10:27:57 pm »
Hello, I have been having this problem for a while but I think i have pinpointed what is wrong, i can't fix it though.
When trying to create a project, such as a "Hello World!" application  , the first time running it the process works as intended.
After modifying it, for example to display ,,"Hello World! JUFHDUSF"  i can no longer compile, as I am getting the error
Code
 ld.exe||cannot open output file bin\Debug\bunaziualume.exe Permission denied|
||=== Build finished: 1 errors, 0 warnings ===|

Going to the folder that the program is in, i notice it is Read-Only grayed out. If I try to modify this value very soon after I run the program it says I don't have permission to change it.
If I wait a while, it allows me to change the value but continues being grayed out after I do so if I click on the folder again.

I would also like to mention that after a while (10-15 minutes)  if I try to run the modified program it works for some reason.

I really need help with this ,thank you!

zabzonk

  • Guest
Re: Permission Denied ; Code-Blocks making files read only
« Reply #1 on: April 13, 2012, 11:09:43 pm »
This is not a codeblocks issue - if you compile the code from the command line you will get the same problems. In my experience, it's an issue with your anti-virus and/or firewall software. Shutting them both down, rebooting and then restarting them will normally fix it. But as I said this is NOT a CB issue.

Offline obidan

  • Single posting newcomer
  • *
  • Posts: 4
Re: Permission Denied ; Code-Blocks making files read only
« Reply #2 on: April 14, 2012, 07:21:21 pm »
I don't have an anti-virus and have disabled my firewall and rebooted my PC, it still doesn't work.
For some reason the file is read-only for about 3 minutes or so until it suddenly changes or i donno.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: Permission Denied ; Code-Blocks making files read only
« Reply #3 on: April 14, 2012, 07:31:26 pm »
I don't have an anti-virus and have disabled my firewall and rebooted my PC, it still doesn't work.
For some reason the file is read-only for about 3 minutes or so until it suddenly changes or i donno.

Unlikely, it is more likely your exe is still running for a few minutes.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline obidan

  • Single posting newcomer
  • *
  • Posts: 4
Re: Permission Denied ; Code-Blocks making files read only
« Reply #4 on: April 14, 2012, 07:35:07 pm »
And what would I be able to do in this case?
I run a Windows 7 64 Bit PC

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: Permission Denied ; Code-Blocks making files read only
« Reply #5 on: April 14, 2012, 07:56:57 pm »
http://support.microsoft.com/kb/323527

"Exit a program" should result in the program being killed.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline obidan

  • Single posting newcomer
  • *
  • Posts: 4
Re: Permission Denied ; Code-Blocks making files read only
« Reply #6 on: April 14, 2012, 07:59:36 pm »
The exe isn't running in Task Manager and I used ProcessExplorer to see that it is used by the C++ debugger. Can't close it for some reason , even inside that.( Error opening process: The handle is invalid)
« Last Edit: April 14, 2012, 08:06:18 pm by obidan »