DAY 044: RESET - Printable Version +- QB64 Phoenix Edition (https://qb64phoenix.com/forum) +-- Forum: Official Links (https://qb64phoenix.com/forum/forumdisplay.php?fid=16) +--- Forum: Learning Resources and Archives (https://qb64phoenix.com/forum/forumdisplay.php?fid=13) +---- Forum: Keyword of the Day! (https://qb64phoenix.com/forum/forumdisplay.php?fid=49) +---- Thread: DAY 044: RESET (/showthread.php?tid=1357) |
DAY 044: RESET - SMcNeill - 01-02-2023 How many of you guys know this word even exists in our language? The command is RESET, but how many remember exactly WHAT it resets? Or what it's for? This is one of those very important old keywords, that has basically became lost to time. Keyword: RESET Wiki page: https://qb64phoenix.com/qb64wiki/index.php/RESET What's this do: It basically works as a superpowered CLOSE statement. Back in the day, when folks used floppy disks and such, it was necessary to use RESET to write your current directory info to the drive track. Before you ever exited a program, and pulled your floppy out of the drive, you'd issue a RESET command to close all files and update all drive information to the floppy. Nowadays? Who owns a floppy drive? Would a modern OS even require this type of command to update that information, IF you happened to have a floppy drive connected?? I dunno!! All this command does for us now, is basically just work as a CLOSE statement to close all files. It's unused. Obsoleted. Forgotten... ...Maybe I should've saved this keyword for Memorial Day. RIP poor RESET. RE: DAY 044: RESET - mnrvovrfc - 01-02-2023 I had known it exists -- but in TRS-80 BASIC. It had to do with graphics, not files. This "RESET" would have been vital if Galleon's QB64 had to run only from floppy disks LOL, it opened like 30 file handles and relied a lot on a #26 IIRC. "CLOSE" by itself might not have been enough. Does Windows have something like this? Linux has "sync" which is not always reliable. Using USB v2.0 drives could be a real drag moving a few gigabytes around. Windows seems to be stealthier about it but I wish they did something about that dumbass green graph. RE: DAY 044: RESET - Dimster - 01-02-2023 Could it be repurposed? Say rather than For x = 1 to 50:Array(x)=0:Next ' a loop that initializes the array or resets the values back to zero v's Reset Array(1 to 50) RE: DAY 044: RESET - mnrvovrfc - 01-02-2023 Use "ERASE" for that. |