Log in

View Full Version : [SOLVED:] Password for tab on a multipage form



Ringhal
08-28-2014, 03:20 AM
I have a form in Access with multiple pages or tabs. I want to set a password for a specific tab on the form. I have the code that opens a InputBox asking for the password, which allows access to the form if the password is correct. The code will work if I call it on the open event of any form.

I want to know where I should call the code, so that it runs before a tab is opened, allowing or denying access to that tab. I have tried several things: running it on the On Click event for the tab, any of the objects inside the tab (but that asks for the password every time I click the object).

The main is that the code works (so I am not posting), I just need a place to call it.

ranman256
08-28-2014, 05:35 AM
On tab_Change
see that the tab.Value is, this is the current page clicked.

Ringhal
08-28-2014, 06:18 AM
Thanks ranman256 for your help, I couldn't find the right one.