Search results

  1. H

    Hide/Show Ribbon Tab using VBA

    Setting a reference to Microsoft Office 14.0 Object Library did the trick! Thank you all so much for your assistance on this. Thank you's all around!
  2. H

    Hide/Show Ribbon Tab using VBA

    Attached what I am workign with. Started a empty database, added the USysRibbons table and added my ribbon XML in there. Also added my Sub in the only module (modAdminRibbon). I am still getting the error message from above (MS Access can't access the macro or function).
  3. H

    Hide/Show Ribbon Tab using VBA

    I followed this example but still received the same error message in my app: Microsoft Access cannot run the macro or callback function 'adminTabGetVisible'. Make sure the macro or function exists and takes the correct parameters. So, I took my Sub and put it in the file Ari sent, changed the...
  4. H

    Hide/Show Ribbon Tab using VBA

    I'm not looking to give a tab focus, but change it's visibility attribute from "false" to "true." When the app loads, the ribbon is loaded from USysRibbons with the XML I created for my custom ribbon. There are two tabs, with the second starting like this: <tab id="tabMyTabAdmin" label="Admin"...
  5. H

    Hide/Show Ribbon Tab using VBA

    I'm not wanting to hide the entire ribbon, I'm looking to show a tab that is loaded with the ribbon but has its visibility hidden. I'm not seeing any information in the post or the link provided by user Ari referring to targeting tabs.
  6. H

    Hide/Show Ribbon Tab using VBA

    I have a custom Ribbon in Access 2010 and I want one tab (the admin tab) to show only for a particular user. I already have the function written for checking the user and have the tab hidden in the XML but I am not finding a way to target the hidden tab to make it visible. Any suggestions?
  7. H

    Use variable as field name in IIf expression

    so... you're going to enjoy this. i'll start out by mentioning that i did not create this form. hopefully that will allow some of you to forgive me for what's to come (along with the other suggestions for how to better the form). the reason my original code was not working is because i was...
  8. H

    Use variable as field name in IIf expression

    Adding the variable for the control name seems to be causing a problem. Here is what I have: Private Function CountSubjects() Dim i As Long Dim subj As Long For i = 1 To 56 If Me.Controls("S" & i) = -1 Then subj = subj + 1 End If Next i...
  9. H

    Use variable as field name in IIf expression

    That's exactly it. There are 56 checkboxes (named S1-S56) and each time one is checked I am to change the value of a text field (#Subj) to the total number of boxes checked. Currently, what I have done is created an array (array_subj) and added the names of each checkbox to it. Then I do a loop...
  10. H

    Use variable as field name in IIf expression

    What if subj is a string that contains the field name? For instance: subj = "S1" How would I then use the variable in the IIf function? What delimiters would I need to use?
  11. H

    Use variable as field name in IIf expression

    I am needing the value of subject_checked, if true, to be returned as 1 if true and 0 if false. My question here is mainly about the syntax for using the variable inside the IIf function to specify which field I am wanting to check.
  12. H

    Use variable as field name in IIf expression

    I have my variable defined already. I'm not trying to assign the variable to anything; it already has its value assigned to it. What I'm wanting to do is use the variable "subj" inside the IIf function and assign what it returns to a different variable ("subject_checked"). The field I am...
  13. H

    Use variable as field name in IIf expression

    Very new to VBA. I know this question probably has a very simple answer but I'm not able to find anything about it on the interwebs. When using the IIf function, I am wanting to use the value of a variable ("subj") to determine which field in the form I am wanting to evaluate. So, if my...
Top Bottom