Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Displaying combo boxes...
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00155144
Message ID:
00155166
Vues:
19
Harry,

The ColumnWidth is in Pixels. Because most fonts used in Windows are proportional, there's not really a way to set a width to a number of characters. You'll probably just have to expirement with the widths until you get what you want. The alias.field, field, field,... syntax is correct. Put in column widths (eg, 100,150) and you should see the results you want.

>Hopefully a simple one (aren't they all when you know how!)
>
>No problem getting a combo box to display the values I want based on the fields in a table. However, the combo box appearance leaves a lot to be desired!
>
>If I only needed a single column, it wouldn't be a problem, but I need two.
>
>I would like, ideally for the width of each column in the dropdown list to reflect the appropriate field length. The first field being 10 - and I need to see all 10. The Second
>field being 45 and I need to see at least the first 30 characters.
>
>Can we do this in the 'columnwidth' property? If so, how?
>
>And how can we get the fields to line up or is that solved by the answer to the previous question?
>
>Next, how do we correctly refer to the fields?
>
>If I list them thus - ADDRESS.ACCREF,ADDRESS.COMPANY
>
>I get an error telling me 'field phrase not found'
>
>If I do it ADDRESS.ACCREF,COMPANY as suggested by the vfp help, then I don't an error, but neither do I see matching companies for each account ref (I just see the first company name in the referred table)
>
>I've tried these variations with rowsourcetypes 2 (Alias) and 5(Fields). No difference.
>
>Lastly, why is it that despite having set a (compromise) column width of 20, I'm only seeing the first 3 characters of the first field?
>
>I've hunted high and low for working examples of combo boxes doing things the way I need them done but no joy so far.
>
>Anyone been there, seen it, done it?
>
>Thanks
>
>Harry
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform