Secure one Tab on a form

RichB

New member
Local time
Today, 14:06
Joined
May 15, 2001
Messages
96
Is it possible to password one tab on a form? I have a form that lists all of the people in the church. This list is linked to 4 tabs with subforms. I want the last tab to be password protected. I want this to be a form with a memo field for the pastors comments.

Any thoughts
Thanks
Rich:D
 
Having had a play I think the best way is to make the tab hidden and only show it if the pastor is logged in or allow access to viewing via a button with password code.
 
You could do something like this:
Code:
Private Sub tabView_Change()
On Error GoTo errorHandler

    DoCmd.Echo False
    If tabView = 1 Then ' 1 being the page number you want to password protect
        If InputBox("Enter Passord") <> "Holy" Then
            MsgBox "Incorrect Password"
            tabView = 0 ' reset back to first page if password incorrect
        End If
    End If
    DoCmd.Echo True
    
exitHandler:
    DoCmd.Echo True
    Exit Sub
errorHandler:
    MsgBox Err.Description
    Resume exitHandler
End Sub

Dave
 

Users who are viewing this thread

Back
Top Bottom