Author Topic: *** ERROR - Can't overwrite program. Is it still running?  (Read 7861 times)

MrTAToad

  • Guest
There seems to be a problem in Vista whereby, even if a program ends normally, and you attempt to re-compile the program, the linking message *** ERROR - Can't overwrite program. Is it still running? still appears.

It should be noted that there are NO processes belonging to GLBasic nor the executable.

Offline Hemlos

  • To boldy go where no pixel has gone before!
  • Global Moderator
  • Prof. Inline
  • *******
  • Posts: 1634
  • Particle Hawk
    • View Profile
Bummer.


Does it do that if you select "Start a copy" too?
Volume_of_Earth(km^3) = 4/3*3.14*POW(6371.392896,3)

Offline Schranz0r

  • Premium User :)
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 5019
  • O Rly?
    • View Profile
you use inline right?
I <3 DGArray's :D

PC:
AMD RYzen 7 1700 @3.9Ghz, 16GB HyperX Fury 2666Mhz Ram, ASUS ROG GTX 1060 STRIX 6GB, Windows 10 Pro 64Bit, MSi Tomahawk B350 Mainboard

MrTAToad

  • Guest
No INLINE is used.

The problem seems to occur when no graphics screen is created - for example with the follow :

Code: GLBasic [Select]
ok=OPENFILE(0,"filelist.txt",TRUE)
DEBUG "OK : "+ok+"\n"
DEBUG "File exists : "+DOESFILEEXIST("filelist2.txt")+"\n"
KEYWAIT

Unfortunately it cant be stopped with the debugger options either (but only if not debugging).

Offline Hemlos

  • To boldy go where no pixel has gone before!
  • Global Moderator
  • Prof. Inline
  • *******
  • Posts: 1634
  • Particle Hawk
    • View Profile
No INLINE is used.

The problem seems to occur when no graphics screen is created - for example with the follow :

Code: GLBasic [Select]
ok=OPENFILE(0,"filelist.txt",TRUE)
DEBUG "OK : "+ok+"\n"
DEBUG "File exists : "+DOESFILEEXIST("filelist2.txt")+"\n"
KEYWAIT

Unfortunately it cant be stopped with the debugger options either (but only if not debugging).

I remember reporting this a few years ago actually, while using windows xp.
Correct me if im wrong, but from what i understand; showscreen is essential for glbasic to function properly.
Something to do with flushing memory.
Volume_of_Earth(km^3) = 4/3*3.14*POW(6371.392896,3)

MrTAToad

  • Guest
I wouldn't be surprised with SHOWSCREEN being needed, especially if it also does the message pumping.

happylewie

  • Guest
Try running as 'Admin'. Worked out for me. Had the same problem. ;)

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10708
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Very strange. Take a look at the program's attributes. Can you delete the file?

MrTAToad

  • Guest
Quote
Try running as 'Admin'. Worked out for me. Had the same problem.
Dont worry - I am running as Admin

Quote
Very strange. Take a look at the program's attributes. Can you delete the file?
No, the file is being locked - it cant be deleted.

Its not a worry too much now - as Ocean suggested, as there is no window display it should really be compiled as a console application (which it isn't).  The main problem is that even trying to "End Task" it wont work - the only thing that will is to exit GLBasic.

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10708
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Is it in Debug mode? Please get the Sysinternals ProcesMonitor program, and see if you can see the process running there.

Offline Ian Price

  • Administrator
  • Prof. Inline
  • *******
  • Posts: 4147
  • On the shoulders of giants.
    • View Profile
    • My Apps
I had this yesterday on XP - however, I think it was because I pressed the RUN button twice (I wasn't sure if it was compiling/running or not, it didn't look like it was) and it was trying to run two instances. Dunno.
I came. I saw. I played.

MrTAToad

  • Guest
Quote
Is it in Debug mode? Please get the Sysinternals ProcesMonitor program, and see if you can see the process running there.
Yes, this is debug mode.  In the ProcessMonitor, the last entry (when the debugger is used to stop the program), is :

17:17:45.9630984   tEST2.exe   2384   Thread Exit      SUCCESS   Thread ID: 2112, User Time: 1.2012077, Kernel Time: 8.9076571

And it can't be re-built due to still "running"

When GLBasic is quit, the last line for test2.exe is :

17:20:16.3957162   tEST2.exe   2384   Process Exit      SUCCESS   Exit Status: 0, User Time: 1.2948083, Kernel Time: 9.5160610, Private Bytes: 18,886,656, Peak Private Bytes: 43,175,936, Working Set: 17,137,664, Peak Working Set: 21,925,888

Offline Steinbock

  • Mr. Drawsprite
  • **
  • Posts: 63
    • View Profile
    • Mountainsoft
Hi

Was there any solution for this? Because i have the same problem on my new pc. Windows 7 Home Premium 64bit.
Same code worked fine on (old) XP.  O_O
Time will come. It's just a matter of time...

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10708
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
can you delete the old exe file in windows explorer?

Offline Steinbock

  • Mr. Drawsprite
  • **
  • Posts: 63
    • View Profile
    • Mountainsoft
Yes, it's possible.
Time will come. It's just a matter of time...