Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Combo Box
Message
De
14/10/2001 09:50:51
 
 
À
14/10/2001 06:00:43
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Divers
Thread ID:
00568259
Message ID:
00568274
Vues:
14
Hi Carlos.

>> I have a table index on "Clients.Name" and I have a combo Box to select Clients, I want the table be displayed in Alfabethic order in the combo Box. How to do that? <<

I take it that you want to use the combo box as a way to navigate to different clients in your clients table. If this is the case, the easiest way to set up your combo box is to make sure the clients table's controlling index is set to the Name index when you open the table in the form and set the combo's properties as follows:

RowSourceType = 6-Fields
RowSource = Clients.name, iclientPK (that is, assuming that you are using a primary key on you clients table called iClientPK).
BoundColumn = 2
BoundTo = .T.
Style = 2

You can leave the ControlSource of the combo blank. Whenever a new client is selected in the combo, the record pointer in the clients table will move to that client record. So if you have other controls on the form that are bound to fields in the client table, all you need to do is put a Thisform.Refresh() in the combo's valid to display the selected client info in the form.

HTH.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform