10-20-2024, 06:04 PM
(10-20-2024, 03:55 PM)bplus Wrote: Ah in case I accidently delete the .bas instead of the EXE. Thanks
Or, as was posted so perfectly on the Discord:
Quote:Weird question, but is there a way to get back the .bas version of a .exe please? I made programs, but I lost the .bas, and only have the .exe
Which is why, if you embed the source with the EXE, you never have that issue. It's a great way of doing things, if you tend to create EXE files and use them as various utilities on your PC and yet upgrade QB64PE versions into new folders and such, and those BAS source files get lost/buried/archieved elsewhere over time.
For less than 10 lines of code, you can now write your programs so that the EXE itself will contain the BAS sources and you can always retrieve it for you. (14 above, with lines of space and comments which can be stripped out easily.) It's one of those little utilities/habits that anyone could adopt incredibly easy, yet which we all tend to just gloss over and overlook (a lot like adding comments to code when we're in the zone and coding like a drunk monkey on cheetos). It's also the type of thing which we always look back on and then go, "GAH! WHY DIDN'T I DO THIS?!!"
As I like to watch people squirm and suffer, I just had to share this. Now, in the future when they ask about getting their source code back from the EXE, I can giggle like an Evil Overlord and point them to this thread and say, "I KNEW THIS WAS GOING TO HAPPEN! If you guys would just all listen to me, like good little minions... errr.... programmers!"