Information générale
Catégorie:
Gestionnaire d'écran & Écrans
Sorry, I answered too fast without reading close enough. (I also replied once to the wrong message, not my day <g>)
Assuming your forms ScaleMode is set to pixels can you do something like this:
Get the width of the editbox.
Use FontMetric to get the average width for the font your using.
Multiply this average times the len(editbox.text) to get a width.
Divide this with by the number of columns (the width) in your editbox.
Round up.
>This doesn't seem to work for me, as it fails to take into account line wrapping within the editbox. (MEMLINES() is returning 2 for an edt that has 10 lines of wrapped text.
>
>-- jas
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement