Greyed out a field

V

Vina

I have a form that runs a report and it has fields for
criteria, can someone give me an idea how i can hve a
field lock or greyed out if the report doestn require
that criteria?

Thanks
Vina
 
K

Kevin Sprinkel

Hi, Vina. Try

DoCmd.OpenReport "yourcriteriaformname"
Forms!yourcriteriaformname!txtUnneededfld.Enabled = False

HTH
Kevin Sprinkel
 
J

James Goodman

You can set this through VBA:

'To grey
Me!ControlName.Enabled = False

'To clear & enable
Me!ControlName.Enabled = True
 
V

vina

Thank you this works!!!
-----Original Message-----
Hi, Vina. Try

DoCmd.OpenReport "yourcriteriaformname"
Forms!yourcriteriaformname!txtUnneededfld.Enabled = False

HTH
Kevin Sprinkel

.
 

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