Solved

Is there a RibbonX attribute that I can set on a tab that will minimize the tab?

Posted on 2011-09-03
3
356 Views
Last Modified: 2012-05-12
I have a USysRibbons file in Access 2007 that removes all default ribbon tabs and displays my one custom tab, but I want to ensure that my custom tab is minimized by default. Is there an attribute that I can set on my custom table to minize it?
0
Comment
Question by:RiverWalk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Author Comment

by:RiverWalk
ID: 36480442
I found this code to minimize the ribbon.

if Application.CommandBars.Item(“Ribbon”).Height > 100 then
        SendKeys “^{F1}”, True
end if

I mainly want to minimize the Ribbon on startup only, so this might work for me, but I have ready several references from people saying that they do not like to use Send Keys. Can you please tell me why people might not like using Send Keys? Are there some problems inherent with using Send Keys?

Thank you,
RiverWalk
0
 

Author Comment

by:RiverWalk
ID: 36480482
Actually, once I implimented the above code, it did not work. No error messages, but it is not working.

I placed it in a function, like so....

Function MinimizeRibbon()
  If Application.CommandBars.Item("Ribbon").Height >= 100 Then
    SendKeys "^{F1}", False
  End If
End Function

And called it in the Form Open event, like this....

Call MinimizeRibbon

But nothing happens and the Ribbon is not minimized.
0
 
LVL 30

Accepted Solution

by:
hnasr earned 500 total points
ID: 36481934
I tried the function in a module and the code works.

SendKeys issues a key sequence for the open window.
See the efect by setting a break point after the call MinimizeRibbon statement, and the effect will be opening the help system.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes two methods for creating a combo box that can be used to add new items to the row source -- one for simple lookup tables, and one for a more complex row source where the new item needs data for several fields.
You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question