Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How can I intercept Ctrl+A in a form?
Message
 
 
À
09/11/2001 11:08:36
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00579379
Message ID:
00579688
Vues:
25
>>>>My application is running under our custom menu, which already has Item (Select All) with Ctrl+A hotkey. So, I don't understand, what should I do.
>>>
>>>In the Select All menu item, instead of calling what you'd normally would, call method of the form that selects all the items in your list. This could be a nice use for reusable hooks.
>>
>>Mike,
>>
>>Sorry again for being such a dumb, but the main menu is not from my application, it's from top-level application and it uses standard windows items, e.g. it's standard Edit menu with all options. How can my form temporary substitute this menu item with my item and restore it back, when form finishes?
>>
>>As I said, it seems too complicated and not worth the whole original idea...
>
>In that case you should disable that piece of menu in listbox's .gotfocus and restore it in the .lostfocus, which seems like a major hassle. Why not just use the asterisk for the key, plus for select single and minus for deselect single? It's the standard keys used in several clones of Norton Commander (don't remember the NC itself because the clones were far better).

I solved this problem by ON KEY LABEL Ctrl+A _screen.activeform.SelectAll() in GotFocus and On Key Label Ctrl+A in LostFocus. I agree, this is not elegant (? sp), but it's sufficient. Besides, users didn't ask for this functionality, I just thought, that it would be nice to have. Not sure, that * would be better, don't remember, if I've seen this interface anythere...
If it's not broken, fix it until it is.


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

Click here to load this message in the networking platform