home *** CD-ROM | disk | FTP | other *** search
- R E S T A R T I N G C P / M P R O G R A M S
-
- Occasionally, when I notice a trivial bug in a basic program, I'll
- load the program, make the change, and run the program. Then, 1 out of
- 10 times (on a good day), I'll enter "SYSTEM" and realize that I never
- saved the program to disk. Oh well, time to retype it right? Not if
- you use one simple fact of the CP/M program loader: If you load a 0k
- program, the CCP will read in no records (which effectively leaves the
- TPA unchanged) and starts execution at the start of program code. This
- effectively restarts the program, and in the case of microsoft basic
- (and probably others), leaves the program intact!!! Thus, you can save
- the program. The easiest way to implement the restart program is to
- save "RESTART.COM" with 0K. "SAVE 0 RESTART.COM" Then, when you goof
- and exit MBASIC before saving your program, you can simply say "RESTART"
- and voila! mbasic will respond with ok! This simple technique has
- saved my computer many a beating...
-
- Joe Pluta
-