Enabling a whole Tab

  • Thread starter Thread starter Ryis
  • Start date Start date
R

Ryis

Hello,

I have a form with 6 tabs, one of which is labeled "HEAD OFFICE USE ONLY".
I have a hidden form which has a sub form with a permission level field(in
datasheet view), what i am trying to do is have this tab stay disabled
unless the PERMISSION LEVEL = a certain value. with in this tab there are
4-5 fields. I have set the enabled to no for my tab control but cannot
figure out the code to enable it..

Any help would be appreciated

Ryan
 
Ryis,

It would be something like this. You will need to play with the format.

Place code in the current event of the main form like this:

If [HiddenFormName].Form.[SubformName].Form![PermissionLevel] =
"WhateverValue" then
[TabName].Enabled = True
End If

[TabName] would be the Name property of the tab when you click on it in form
Design View.

Without testing I think that this syntax for addressing the subform is
correct,

[HiddenFormName].Form.[SubformName].Form![PermissionLevel]

If I understand you, there is a hidden subform with a subform in your main
form.

God Bless,

Mark A. Sam
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top