Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to auto size grid columns
Message
 
 
À
03/10/2004 06:09:14
Michael Ouellette
Australian Technical Services (VIC) Pty
Australie
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00948300
Message ID:
00948329
Vues:
15
Michael,

Have you predefined the column count of your grid? Your multiplier needs to take into account the FontMetric() for your font into account.

VFP by itself will construct the grid with columns that are 20% too wide for wide character fields when you have mixed case text of a proporional font.

>How do I automatically size my grid columns so all the text fit?
>
>I tried this but the width is too small:
>with this
> * replace default column header with custom header class
> FOR liColIndex=1 TO .ColumnCount && loop through all grid columns
> WITH .Columns(liColIndex)
> .width = fsize(.Header1.Caption)
> endwith
> endfor
>endwith
>
>I'm guessing there must be a multiplier?
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform