Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ON KEYLABEL DEL DO CLASS??
Message
De
22/10/1997 18:39:19
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00055377
Message ID:
00056202
Vues:
39
>>100% agreed. ON KEY LABEL has some cons and some pros. It depends what you want to do, in my opinion. Sometimes you may want your shortcut keys to interrupt whatever other code is running. Anyway, it's clear that you can't do anything in an ON KEY LABEL and that, whatever you do, you must be very careful. But it was almost the same in FP 2.6. I also believe that if the on key label action can break the app, it means it's a bug there. If the bug can't be fixed, the error is the fact that there is an OKL! :) But there are harmless actions that can be used with OKLs. BTW, I had a request for an OKL that will display the date format (ymd, mdy, etc) in a WAIT WINDOW NOWAIT. Do you see a case when this can blow up my app?
>>
>>Thanks.
>>
>>Vlad
>Vlad,
>
>There is an alternative to OKL in both VFP and FP 2.x, in VFP it is using the Keypress, in 2.x it is the menu shortcut key on a popup that is not displayed. You are correct in that if you need to interrupt running code (like with a cancel option) then an OKL is the ONLY option, but, IMO, OKL's should only be used where interrupting running code is the goal.
>
>As for the WAIT WINDOW it could cause problems in a tightly timed loop where the execution speed is critical to the operation. A single wait window could throow off the execution performance.

Thanks for your input.

Vlad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform