|Simple help system for Clipper programs.|
|File Name||File Size||Zip Size||Zip Type|
Download File CLIPHELP.ZIP Here
Contents of the HELP.TXT file
The following code is an example of a help system for Clipper S87.
It uses a technique that I have not seen documented anywhere but
lends itself to this purpose quite nicely. With a seperate HELP
database, you can create very extensive context sensivtive help
systems for you applications and, with seeking on all three
varibles (P,L,V), a help screen can be located and displayed within
a second. Of course as the size of your help system grows so will
your index; disk space should be a consideration during development.
An explanation for the novice:
When the F1 key is pressed, the procedure HELP is looked for and
executed (It must be compiled and linked with the system). Three
parameters are passed: calling program (P), calling line (L), and
calling varible (V). You enter your HELP database and seek on the
concaction of these varibles. Lines 4-6 and 13-16 were put in to
run this procedure as a stand alone program. They are not needed
for an on-line help and have been commented out and are left in
only as a reference. When a match is found, the HELP screen is
displayed in the window defined with the fields top, left, bottom,
and right. The function memoedit is use in the non-update mode.
If a match is not found then a no help message is displayed (line 26).
A more appropriate window and message should replace line 26.
The HELP database structure should look like this:
FIELD NAME TYPE WIDTH
Call_Prg Char 10
Call_Line Char 4
Call_Var Char 10
Text Memo 10
Top Num 2
Left Num 2
Bottom Num 2
Right Num 2
and should be indexed on call_prg+call_line+call_var to HELP.NTX
An example of a record in this database might be:
Text You must enter a yes or no response
the -'s represent leading blanks in the fields.
Please feel free to use and distribute this code anyway you wish.
Comments can be sent to me on COMPUSERVE 73767,1473.
1 PROCEDURE HELP
2 PARAMETER P,L,V
4 *P = SPACE(10)
5 *L = 0
6 *V = SPACE(10)
8 SET TALK OFF
9 SET EXACT OFF
10 frame = ""
13 *@ 4,10 SAY "ENTER PROGRAM " GET P PICTURE "!!!!!!!!!!"
14 *@ 5,10 SAY "ENTER LINE " GET L PICTURE "####"
15 *@ 6,10 SAY "ENTER VARIBLE " GET V PICTURE "!!!!!!!!!!"
18 USE HELP INDEX HELP
19 seeker = p + str(l,4) + v
20 SEEK seeker
22 IF FOUND()
23 @ top,left,bottom,right BOX frame
26 ? "NO HELP IS AVAILABLE"
December 10, 2017 Add comments