Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Edit Box
Message
De
24/08/2000 21:54:20
 
 
À
24/08/2000 18:54:23
Andy Roth
Neyenesch Printers
Californie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Divers
Thread ID:
00409041
Message ID:
00409075
Vues:
21
>I have an edit box that lists 2 columns when the pull down is activated. I would like either to search on the first column
>and have the 2nd coumn be used or search on the 2nd column and the first column be used.
>Example:
>Cursor reps - 2 fields repno & rep name
>
>the edit box has the first column repno and I want to search on rep name
>or first column be rep name and I want to search on repno
>
>In any case I want the data found to be repno in the edit box field
>or
>be able to assign the value in repno to a variable
>lcRepno=Thisform.StartRep.Value
>even thought the repno is the 2nd column in the edit box.
>
>Thanks

Combobox, not edit box, unless you know something I don't ;)

To get the 2nd column value into the Value, and therefore the ControlSource field, set these properties..

combo.BoundColumn = 2
combo.BoundTo = .T.

If you don't want to bind the combobox to this column, you can still get the 2nd column value with..

lcRepNo = combo.List(combo.ListIndex, 2)
Insanity: Doing the same thing over and over and expecting different results.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform