Can you disable a control on a form.....?

G

GertLab

Can you disable a control on a form without "greying out" the control?
Its Hard to read grey text on grey background when you disable a textbox.
Can you change the text Colour?
 
R

Rick Brandt

GertLab said:
Can you disable a control on a form without "greying out" the control?
Its Hard to read grey text on grey background when you disable a
textbox. Can you change the text Colour?

Set Enabled = False and Locked = True.
 
D

Douglas J Steele

Try setting its Locked property to True, rather than its Enabled property to
False.
 
Y

yarra

Sorta helpful, but sorta not! This changes the text colour as desired, but
unfortunately it means that the control can now have the focus - users can't
change it, but when tabbing through the form they have to tab past a lot of
locked controls. Not a major problem, but annoying all the same. Is it
possible to set the properties so that the control can't have the focus, but
is still readable (ie black text, not grey-on-grey)?
 
R

Rick Brandt

yarra said:
Sorta helpful, but sorta not! This changes the text colour as
desired, but unfortunately it means that the control can now have the
focus - users can't change it, but when tabbing through the form they
have to tab past a lot of locked controls. Not a major problem, but
annoying all the same. Is it possible to set the properties so that
the control can't have the focus, but is still readable (ie black
text, not grey-on-grey)?

Enabled = False
AND
Locked = True
 
D

Damon Heron

Set the tab stop property to no and the tab will go past those locked
textboxes.

Damon
 
R

Rob Parker

If you set Locked to Yes, and Enabled to No, the control does not become
"greyed out", and it cannot gain focus.

HTH,

Rob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top