Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ComboBox RecordSource Options
Message
 
À
07/10/1998 23:38:18
Jim Underwood
Apollo Information Systems, Inc.
Houston, Texas, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00144858
Message ID:
00144892
Vues:
22
Jim,

>1. Are you sure about putting the code in the WHEN of cboState? At that
> point cboState hasen't changed, right? Also, wouldn't it be better in the
> LostFocus than in the InteractiveChange?

A list and combobox fire the WHEN before they get focus and every time the selected item changes. The LostFocus only fires on the contrl losing focus. The WHEN is better suited for your purposes.

>2. Do I gather correctly that it is better to use the .value rather
> than the control's ControlSource in the WHERE clause of the cboCity
> RowSource? Can you share the pros/cons of both approaches?

The Value will hold the selected item's value, the controlsource is where the value came form. When a user is in the combo and they changed the selected item, the controlsource will not be updated until they leave the combo. The Value property is updated in real time as the user makes their chioces. By using teh WHEN to call teh requery and the Valkue for the WHERE clause you can have the city combo dynamically update whenever the user selects a new state. The user won't need to leave the state combo for the city combo to be updated.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform