Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Label control
Message
De
08/07/2001 18:31:35
Nancy Folsom
Pixel Dust Industries
Washington, États-Unis
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00527963
Message ID:
00527967
Vues:
39
This message has been marked as the solution to the initial question of the thread.
Bob-

>I have a few labels, I use as buttons. I set the captions, and in the click event I put some code, to launch code.
>
>the captions, I just added a \< to enable hot keys. I can hot key to the label, (the color changes, a little,) but to actually get it to do anything I have to use the mouse click.

Right. Label's don't get focus. The reason we put accelerator keys on labels is because when the keystroke fires, since the label can't get focus, the next control in the tab order receives the focus.

>Since there is not a keypress method on the label control ... and I have not found a way to put one there. I am stuck.

I think Iain's suggestion is the correct one for you.

>But I find it strange you can hot key to a label.caption, but can't get it to activiate the click method.

It has to be this way. Since we really want an accelerator key to work on control that can do things, and since those controls don't have captions that the user can see, we need the two elements.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform