Argox PA-20 Basic Programming Manual Manuel d'utilisateur Page 38

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 143
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 37
PT-Basic Programming Manual Ver. 1.00 37/143
LOCK
Purpose
To hold all the activated event triggers until they are released
by UNLOCK.
Syntax
LOCK
Example
ON KEY(1) GOSUB F1
ON KEY(2) GOSUB F2
F1:
LOCK
PRINT "press F1"
UNLOCK
RETURN
F2:
PRINT "press F2"
RETURN
In this example, the BASIC program can trap the KEY(1)
and KEY(2) events and reroute to the subroutines F1 and F2
respectively. In F1, the command LOCK disable all the
activated event triggers so that the subroutine F1 will not be
interrupted by a new upcoming KEY(1) and KEY(2) event.
On the other hand, since LOCK is not called in F2, any new
coming KEY(1) and KEY(2) event will interrupt the ongoing
F2, and therefore, may affect the expected results.
Description
This command can prevent nesting of event triggers. All the
activated event triggers will be disabled until UNLOCK is
called.
Vue de la page 37
1 2 ... 33 34 35 36 37 38 39 40 41 42 43 ... 142 143

Commentaires sur ces manuels

Pas de commentaire