Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ACTIVE textbox color
Message
De
15/05/2003 15:45:41
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00788927
Message ID:
00788978
Vues:
22
>>>In 1 fell swoop statement Am I able to have each textbox's forcolor take on a color of my choice when it gets the focus, then revert back when focus lost?
>>
>>In your textbox base class add two custom properties MyForeColor and SaveForeColor.
 * GotFocus event
>>THIS.SaveForeColor = THIS.ForeColor
>>THIS.ForeColor = This.MyForeColor
>>* LostFocus - restore ForeColor
>>THIS.ForeColor = THIS.SaveForeColor
>
>I figured that would work but 1 thing I didn't mention was that this form is an older one and all the textboxes are based on the orig native textbox class. :-(

Then you'll either have to change each and every TextBox, or you'll have to change all of them to be a sub-classed TextBox.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform