R
RemySS
Hi all,
I have a text field, and two icon labels pasted from the symbols in Word
(one a tick, the other a cross) on my form. I want the cross to be visible
when the field is blank (this includes when the form is closed and opened
again) and the tick to be visible when the field has data in it (in this case
I have a date input mask, e.g. 21/09/2005). Of course, I dont want the labels
to be visible at the same time.
p.s. in the icons labels properties dialog box, the class is
"Word.Document.8" if that makes any difference.
The code i tried to do this with is below:
Private Sub Completed_F10_Issued_to_HSE_Change()
If Forms![South_Tracker_Rollout].[Completed_F10_Issued_to_HSE] = Blank Then
Form_South_Tracker_Rollout.Yes2.Visible = False
Form_South_Tracker_Rollout.No2.Visible = True
Else
Form_South_Tracker_Rollout.Yes2.Visible = True
Form_South_Tracker_Rollout.No2.Visible = False
End If
End Sub
I placed this in the text fields On Change event. This works in a way, but
doesnt update when the form is reloaded, nor does it change if i make the
text field blank again. I'm sure its really simple but my VB is amatuer
level, could anyone help?
Thanks in Advance,
I have a text field, and two icon labels pasted from the symbols in Word
(one a tick, the other a cross) on my form. I want the cross to be visible
when the field is blank (this includes when the form is closed and opened
again) and the tick to be visible when the field has data in it (in this case
I have a date input mask, e.g. 21/09/2005). Of course, I dont want the labels
to be visible at the same time.
p.s. in the icons labels properties dialog box, the class is
"Word.Document.8" if that makes any difference.
The code i tried to do this with is below:
Private Sub Completed_F10_Issued_to_HSE_Change()
If Forms![South_Tracker_Rollout].[Completed_F10_Issued_to_HSE] = Blank Then
Form_South_Tracker_Rollout.Yes2.Visible = False
Form_South_Tracker_Rollout.No2.Visible = True
Else
Form_South_Tracker_Rollout.Yes2.Visible = True
Form_South_Tracker_Rollout.No2.Visible = False
End If
End Sub
I placed this in the text fields On Change event. This works in a way, but
doesnt update when the form is reloaded, nor does it change if i make the
text field blank again. I'm sure its really simple but my VB is amatuer
level, could anyone help?
Thanks in Advance,