If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Code for Tabs on a Form
I created a page on my form (using Tab Control from the toolbox) called
Maintenance Users Only. I set the visible property for that page to NO. From another page on the form I have a command button that when clicked runs an Inputbox to ask the user for a password. If the user enters the correct password, I want the page, called "Maintenance Users Only" to become visible. I can't come up with the proper syntax to specify the "Maintenance Users Only" page. If I wanted a correct password to make a field visible, I would type [Forms]![FrmMainForm]![fieldname].Visible = 0 but what is the right way to specify the page? |
#2
|
|||
|
|||
Code for Tabs on a Form
LLFK,
If you wanted a correct password to make a control visible, you would type: Me.fieldname.Visible = True It is exactly the same with the page on the Tab Control. In design view of the form, select the page, and then look at the properties. In particular the Name property, which will tell you the name of the page. Then your code will be like this: Me.NameOfPage.Visible = True -- Steve Schapel, Microsoft Access MVP LLFK wrote: I created a page on my form (using Tab Control from the toolbox) called Maintenance Users Only. I set the visible property for that page to NO. From another page on the form I have a command button that when clicked runs an Inputbox to ask the user for a password. If the user enters the correct password, I want the page, called "Maintenance Users Only" to become visible. I can't come up with the proper syntax to specify the "Maintenance Users Only" page. If I wanted a correct password to make a field visible, I would type [Forms]![FrmMainForm]![fieldname].Visible = 0 but what is the right way to specify the page? |
Thread Tools | |
Display Modes | |
|
|