I have a control on a form. The name of the control is STATUS.
If the data in STATUS shows to be “Inactive” I would like a label to be
visible.
The name of the label in question is lblInactive.
I would like lblInactive to read “This is an inactive file.”
Otherwise, I would like for the label named lblInactive to not be invisible.

Signature
Jerry Wright
fredg - 11 Sep 2007 17:39 GMT
> I have a control on a form. The name of the control is STATUS.
> If the data in STATUS shows to be “Inactive” I would like a label to be
> visible.
> The name of the label in question is lblInactive.
> I would like lblInactive to read “This is an inactive file.”
> Otherwise, I would like for the label named lblInactive to not be invisible.
Set the label's Caption to
“This is an inactive file.”
without the quotes.
Code the Status AfterUpdate event:
Me![lblInactive].Visible = Me![Status] = "Inactive"
Place the same code in the form's Current event.

Signature
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
Chris Reveille - 11 Sep 2007 17:46 GMT
Assuming this is a single form.
In the On current event of the form put
If me.STATUS ="Inactive" then
me.lblInactive = "This is an inactive file."
me.lblInactive.visible = true
else
me.lblInactive.visible = false
end if

Signature
Chris
> I have a control on a form. The name of the control is STATUS.
> If the data in STATUS shows to be “Inactive” I would like a label to be
> visible.
> The name of the label in question is lblInactive.
> I would like lblInactive to read “This is an inactive file.”
> Otherwise, I would like for the label named lblInactive to not be invisible.
JL Wright - 11 Sep 2007 18:22 GMT
Chris
I took out
-- me.lblInactive = "This is an inactive file."
and it works just fine.
Thanks so much.
Jerry Wright
> Assuming this is a single form.
> In the On current event of the form put
[quoted text clipped - 11 lines]
> > I would like lblInactive to read “This is an inactive file.”
> > Otherwise, I would like for the label named lblInactive to not be invisible.