R
Roger Bell
I have written an OnChange Event procedure in the properties of a Control Tab
as follows: This works fine for the Tabctrl Page 7, but does not work for the
Page 4.
Could anyone please tell me where I have gone wrong?
Thanks for any help
Private Sub TabCtl0_Change()
rctMask.Visible = True ' Mask page 7
If Me!TabCtl0 = 7 Then
If Not InputBox("Please Enter Password") = "roger" Then
Me!TabCtl0 = 0
MsgBox "Sorry, Incorrect Password"
Else
'show the tab page
rctMask.Visible = False
End If
rctMask1.Visible = True ' Mask page 4
If Me!TabCtl0 = 4 Then
If Not InputBox("Please Enter Password") = "roger" Then
Me!TabCtl0 = 0
MsgBox "Sorry, Incorrect Password"
Else
'show the tab page
rctMask1.Visible = False
End If
End If
End If
End Sub
as follows: This works fine for the Tabctrl Page 7, but does not work for the
Page 4.
Could anyone please tell me where I have gone wrong?
Thanks for any help
Private Sub TabCtl0_Change()
rctMask.Visible = True ' Mask page 7
If Me!TabCtl0 = 7 Then
If Not InputBox("Please Enter Password") = "roger" Then
Me!TabCtl0 = 0
MsgBox "Sorry, Incorrect Password"
Else
'show the tab page
rctMask.Visible = False
End If
rctMask1.Visible = True ' Mask page 4
If Me!TabCtl0 = 4 Then
If Not InputBox("Please Enter Password") = "roger" Then
Me!TabCtl0 = 0
MsgBox "Sorry, Incorrect Password"
Else
'show the tab page
rctMask1.Visible = False
End If
End If
End If
End Sub