home *** CD-ROM | disk | FTP | other *** search
- *****************************************************************
- * Test program for SAVEGETS and RESTGETS - FILE T_GETS.PRG
- *****************************************************************
-
- * Copyright(c) 1991 -- James Occhiogrosso
-
- # include "inkey.ch"
-
- LOCAL nothing1 := nothing2 := nothing3 := nothing4 := ;
- nothing5 := nothing6 := nothing7 := space(10)
-
- INITGLOBAL()
- SETCOLOR(colstd)
- CLEAR
-
- SET KEY K_F10 TO NEST1 // Set f10 to call first nested read
- CENTERON(MAXROW(), 'Press F10 for next level')
-
- DO WHILE LASTKEY() != K_ESC
- @ 10, 10 GET nothing1
- @ 11, 10 GET nothing2
- @ 12, 10 GET nothing3
- READ
- ENDDO
- RETURN NIL
-
-
- **************
- FUNCTION NEST1
- **************
- SET KEY K_F10 TO NEST2 // Set F10 to next nesting level
- SAVEGETS() // Save current GETS
- @ 17, 10 GET nothing4 // Add new variables to get list
- @ 18, 10 GET nothing5
- READ // Read them
- RESTGETS() // Restore previous set of GETS
- @ 17,10 CLEAR TO 18,20
- SET KEY K_F10 TO NEST1 // ReSet F10 to first nesting level
- RETURN NIL
-
- **************
- FUNCTION NEST2
- **************
- SET KEY K_F10 TO // Clear hotkey F10
- SAVEGETS() // Save current GETS
- @ 17, 40 GET nothing6 // Add new variables to get list
- @ 18, 40 GET nothing7
- READ // Read them
- RESTGETS() // Restore previous set of GETS
- @ 17,40 CLEAR TO 18,50
- SET KEY K_F10 TO NEST1 // ReSet F10 to first nesting level
- RETURN NIL
-
-