Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Textbox control
Message
 
 
To
29/05/1998 09:57:21
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00103062
Message ID:
00103112
Views:
19
Tom,

Just make the KeyPress method:

NODEFAULT

that will prevent any keystrokes from altering the displayed value, but still let your Click() method run and leave ReadOnly set .f. so the color can be changed.

>Basically what I want to do is present a user with a 5 X 5 square of choices. Each cell has specific content through the control source attached from a table. When the user clicks on a choice, the backcolor is changed. Clicking the same choice again toggles it back to the original color. No problem so far...everything works...the only problem is that I do not want the user to be able to change the content. When I set the textbox to readonly, of course it will not take the code in the click() method...so I set readonly to .f. then the code, and then set readonly to .t. It still doesn't work because the control still has focus. Any suggestions? I was going to use a command button, but didn't see a way to change the backcolor easily.
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform