Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Resize control to field size in form designer
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00301020
Message ID:
00301281
Vues:
35
>>How can I resize a control like a textbox or combo to the size of the field that it is bound to? Note: in the form designer, not at runtime.
>>
>>If I drag and drop a field from the dataenvironment this is automatic, but how can I do this after the fact or with my own control classes. I do not want to assign the field a control in the table itself.
>
>Evan,
>
>Here's how I do it, and its not pretty but it works and it is easy.
>
>I put a label in the form and set the font to the same as the textbox. Then I give the label a caption that has the same number of characters as the field, if it is character I use the letter H because it is average width for porportional fonts. Then Idrag the label to just inside the left border of the textbox, click the textbox and use Shift+Arrow to size the textbox so it contains the label well. Then I delete the label.

I am glad you posted this! I do the same thing on the form and report designers.
Mark McCasland
Midlothian, TX USA
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform