Visble feilds based on condition.

G

Guest

Im new to the whole access programming thing so, sorry if this doesnt really
make much sense.
I need to create something that will make a feild in a form visble or not
visble based on two other fields.
for example
If feild 1 is set to saturday and feild 2 is set to evening then feild
3(extended duration) is set to visble.
Thanks for any help.
 
T

tina

you can run code in the form's Current event, and also in the AfterUpdate
events of the two "other" controls (assuming that the data in those fields
can be edited in the form), as

Me!Control3.Visible = (Me!Control1 = "saturday" _
And Me!Control2 = "evening")

hth
 
G

Guest

Ok thanks.
anothe quick question, what is the Me! bit? (ive never done programming in
access before)
 
T

tina

you can use the Me keyword in a form or report module, as a quick way to
refer to the object that the code is running from, instead of using a full
reference such as

Forms!FormName

look up the Me Property topic in Access VBA Help for more information.

hth
 

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