visible if

D

deb

In a form, I have a check box a called CkBoxEHComp and a label called
LabelEHComp
In the format tab I have them set to visible = no

I also have 2 a comboboxs called PMID and ReportDtID(default value is 1).

how can I make the check box and lable visible only if PMID is NOT null and
the ReportDtID NOT= 1

I only want to see the check box if there is a PMID and there is a
ReportDtID other than 1.

PMID isnull and ReportDtID = 1, checkbox and lable not visible
PMID isnull and ReportDtID = 4, checkbox and lable not visible
PMID = 2 and ReportDtID = 1, checkbox and lable not visible
PMID = 2 and ReportDtID = 4, checkbox and lable VISIBLE
 
F

fredg

In a form, I have a check box a called CkBoxEHComp and a label called
LabelEHComp
In the format tab I have them set to visible = no

I also have 2 a comboboxs called PMID and ReportDtID(default value is 1).

how can I make the check box and lable visible only if PMID is NOT null and
the ReportDtID NOT= 1

I only want to see the check box if there is a PMID and there is a
ReportDtID other than 1.

PMID isnull and ReportDtID = 1, checkbox and lable not visible
PMID isnull and ReportDtID = 4, checkbox and lable not visible
PMID = 2 and ReportDtID = 1, checkbox and lable not visible
PMID = 2 and ReportDtID = 4, checkbox and lable VISIBLE

In the form's Current event as well as the AfterUpdate event of the
PMID control and the AfterUpdate event of the ReportDtID control,
code:

Me![CkBoxEHComp].Visible = Not IsNull(Me![PMID]) and Me.[ReportDtID]
<> 1
Me![LabelEHComp].Visible = Not IsNull(Me![PMID]) and Me.[ReportDtID]
<> 1
 

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