Hide and Show Label based on txtBox Value

fenhow

Registered User.
Local time
Today, 11:17
Joined
Jul 21, 2004
Messages
599
Hi,
Looking for a way to hide a label if a textbox shows a value and show the label if the textbox value is a Null.

Thanks.

Fen How
 
Code:
if nz(me.txtbox,"") = "" then
  me.labelName.visible = false
else
 me.labelName.visible = true

The nz will set the value to "" if the control is null. Place the code on the forms On Current Event and the After Update Event.
 

Users who are viewing this thread

Back
Top Bottom