More specific question on @SK
flowersoft at compuserve.com
flowersoft at compuserve.com
Sun Aug 14 04:14:39 PDT 2011
> And it's been like this since... oh, what was current when I rewrote >
Multifile to use indexes in 1996; 4.5? Maybe 4.1. I know @SK didn't >
understand INSL and DELL in that release, so I had to do my own menu >
thing with @WUK to be able to do inserts and deletes.
I wrote an article for the filePro cookBook in February of 1993 called At
When Entering Limbo and certainly at that time, and probably since it very
early days (if not always) filePro @sk has understood INSL and DELL and
every other special key code. It probably difficult to detect them because
many of them did not take you out of the field. I think there was only 1
user key (F8) then. F3 and F4 did nothing except insert and delete lines
while in processing.
For me, the real problem is (was) thet I had never read or heard anywhere
before that @sk gets cleared every time there is input from the keyboard.
Yet, it makes perfect sense. I just never realized it because had never
written code at was shown in the Quiz. I always use labels, like:
1------ ABORT If: @sk="save"
Then: input popup rs "Do You Want to Exit? (Y/n) " default
"Y"
2------ If: ABORT and rs ne "Y"
Then: gosub RESTORE; end
3------ If: ABORT and rs="Y"
Then: exit
4------ If:
Then: end
When you write the code like that, if line #1 is true, then lines #2 and #3
are ALWAYS either true or false based on the input from the user at line #1.
The way the code was written for the Quiz, line #2 and #3 are ALWAYS false,
because filePro clears the value of @sk when the input processing is
executed or more accurately, when the user presses a key while at line #1.
More information about the Filepro-list
mailing list