Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Cancel a process
Message
 
 
À
19/06/2003 17:12:56
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00801951
Message ID:
00801994
Vues:
9
Hi Mathew,

It depends on the process. If, for instance, you're running scan loop, you can use this idea:
lcPrevEsc = on('escape')
lcSetEsc = set('escape')
private plStop
on escape plStop = messagebox('Do you want to Cancel the process?',36, 'Cancel') = 6
plStop = .f.
scan
  if m.plStop
     exit
  endif
...
endscan
* restore environment
>Hi All,
>
>How would I write code to cancel a process when I press the ESC Key? I tried putting the code inside the KeyPress event of a command button, it doesn't work the way I wanted. How could I replace VFP message with my own? TIA
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform