home *** CD-ROM | disk | FTP | other *** search
- 'Name TSTINPUT
- 'Purpose To test the function finput()
- ' Please Note: the project Finput must
- ' be loaded prior to running this program
- 'Written by Jim Heffernan St. Louis Mo.
- ' Member: St. Louis User Group For IBM PC
-
- '*********************** Variable definitions **************
- external finput()
- public $key, $textvar,$txt,$ftxt,$screen,$endhlp
-
- '*********************** End of Definitions ****************
-
- screen clear 15 0
- screen clear box 22 1 25 80 7 0 no-border
- screen print 2 1 10 1 format "M80" " This Procedure Test The Function Finput() "
- screen print 22 1 10 1 format "M80" " Press F10 to Quit... F1 for Help Screen "
- screen draw box 1 1 21 80 15 0
- repaint off
-
- label again
- repaint off
-
- ' parameters for finput = (row,column,foreground,background,length)
-
- finput(5,10,10,9,10)
-
- if cerror <> 0
- message "Function Finput.rf3 Must Be Loaded in Memory First...Press any key"
- jump alldone
- end if
-
- screen clear box 7 15 8 50 7 0 no-border
- screen print 7 15 15 0 "$textvar = "| $textvar
- screen print 8 15 15 0 "$key = "| chr($key)
- screen print 24 1 15 0 "These are the results of Finput()... "
-
- if $key = {F10}
- jump alldone
- '****************** Help screen section ***************************
- elseif $key = {F1}
- locate 1 1 0
- screen save 1 1 22 80 $screen
- error off
- data goto window 1
- data goto view "help.vw"
- if cerror <> 0
- screen clear 7 0
- screen clear box 22 1 25 80 7 0 no-border
- screen clear box 10 20 12 60 15 1
- screen print 11 25 15 1 " Loading Help Screen "
- file load custom-view "help.vw"
- end if
-
- order change key [title]
- data find "[title]" equal "Finput()" options "g"
- if cerror <> 0
- beep 2
- message "Sorry There is no help for this input"
- screen shortrestore $screen
- jump continue
- end if
- screen clear 7 0
- repaint
- screen clear box 22 1 25 80 7 0 no-border
- screen print 22 1 15 1 format "M80" "..Press Esc Key to End Help.."
- label askinchar
- $endhlp = inchar
- if $endhlp = {ESC}
- screen clear box 22 1 25 80 7 0 no-border
- screen shortrestore $screen
- else
- jump askinchar
- end if
- label continue
- file unload view "help.vw"
- end if
- '************************* End of help section *********************
- jump again
- label alldone