Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
ACTIVE textbox color
Message
From
15/05/2003 15:45:41
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00788927
Message ID:
00788978
Views:
21
>>>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
Previous
Reply
Map
View

Click here to load this message in the networking platform