Turbo Pascal Advanced Techniques (Programming Series)
Conditions
Formats
Conditions
Conditions
Formats
Conditions
Audience: Turbo Pascal in the MS-DOS Operating System (not Windows); Not Ancient Turbo Pascal (2,3,4) -- but Turbo Pascal thru version 5.5; Not a person wanting general Pascal (or Turbo Pascal) teaching, but a person wanting to do some advanced things (but not so much math,science,algorithms, i.e. not so much numerical methods, but rather utility tricks) Although the above may sound discouraging and specialist, if you still program in Turbo Pascal for DOS, this book is excellent. Here's a concrete example of how it helped me. Many programs I write do long computations (simulations) or gazillions of replicates of computations (many simulations). So the program may run for a few hours or even a couple of days. What if I want to "control-break" out of the program, i.e. get it to stop? Normally, Turbo Pascal allows control-break (hold your key and then push the [Brk] key) only on I/O -- that is when the program is waiting for a keyboard response. But if the program is off and running doing it's two days worth of simulations, [Brk] would just be ignored and the program will go on merrily doing simulations. You could reboot the computer of course. But wouldn't it be nice if you decided ("oh gosh, I should have used these parameter values when my program asked me!", or "oh I forgot to write down ..." or "oh, dang it, I wanted to print the ... from the computer that is now stuck with two days of simulations", or "oh darn it, I forgot to copy the file to the floppy for my other computer before I started the next simulations run!") that you want to STOP your program via [Brk] and for your program to stop nicely and without problems? Well THIS BOOK tells you how to put an ISR (interrupt service routine) in your program to achieve exactly this goal. And SUCH is a good example of THE KIND OF THING this book is about. Hope this helps you understand the kind of stuff that's in this book.