Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Prevent Double Click
Message
De
20/05/2014 17:08:48
Charlie Schreiner
Myers and Stauffer Consulting
Topeka, Kansas, États-Unis
 
 
À
20/05/2014 15:20:26
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows Server 2008
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01600043
Message ID:
01600354
Vues:
74
I'm making most of this up...
My combos have an IsDroppedDown property. It is set using the following:
PROCEDURE Click()
This.IsDroppedDown = .F.

PROCEDURE DropDown
This.IsDroppedDown = .T.

PROCEDURE KeyPress
LPARAMETERS nKeyCode, nShiftAltCtrl
WITH This
IF m.nKeyCode = ENTERKEY OR (m.nKeyCode = ALTUPARROWKEY AND m.nShiftAltCtrl = ALTKEY)
.IsDroppedDown = .F.
ENDIF
ENDWITH

You can add a IsDroppedDown_Assign() with the normal code in it.

* In a specific combo that you wish to behave this specific way you could override the assgn:
LPARAMETERS NewValue
IF NOT This.IsDroppedDown = m.NewValue
This.IsDroppedDown = m.NewValue
This.Parent.cnt4Area.Enabled = NOT m.NewValue
ENDIF

Add a container, cnt4Area, to your form and put any controls that are in the shadow of the combo's dropdown area into it, but not the combo.

So the DropDown sets the container's Enabled property to .F. The behavior of the container is to disable the controls so any extra click is to no effect. The controls won't react if the container in which they live is disabled. Once the dropdown is over, the container is enabled.
Charlie
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform