calvinc5 Posted June 30, 2014 Share Posted June 30, 2014 Hello I recently changed a lot of things in my script from using find color to using find bitmap. It all works as it is supposed to but then sometimes it just gets a run time error and locks up scar. sometimes when it crashes it also opens up a new empty scar window that is also locked up and it has an error saying something along the lines of "cant find compatible DC". Could this be because I am repetitively checking for the bmp to fast until it is true? Also I was trying to use the command to free the bitmaps but it appears to be gone. Has it just changed or is it not needed? Thank you! Quote Link to comment Share on other sites More sharing options...
FHannes Posted June 30, 2014 Share Posted June 30, 2014 It wasn't needed in the past, it is now. But it's a method of TObject. You can just call it as BitmapVariable.Free. As for the error, I can only guess why it happens unless I can see the script. Quote Link to comment Share on other sites More sharing options...
calvinc5 Posted June 30, 2014 Author Share Posted June 30, 2014 Okay would you mind having a look at it if I send you it? It happened again and made a popup saying "out of system resources" this time. It didn't say run time error this time ether. Quote Link to comment Share on other sites More sharing options...
FHannes Posted June 30, 2014 Share Posted June 30, 2014 Yes, sure, go ahead, I'm guessing that you probably make a lot of bitmaps and never free them so the memory gets clogged. Quote Link to comment Share on other sites More sharing options...
calvinc5 Posted June 30, 2014 Author Share Posted June 30, 2014 I tried using that command like ActionBmp.free; but it says ; expected? Quote Link to comment Share on other sites More sharing options...
FHannes Posted July 2, 2014 Share Posted July 2, 2014 I tried using that command like ActionBmp.free; but it says ; expected? Then you forgot a semicolon somewhere. Quote Link to comment Share on other sites More sharing options...