?
Solved

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

Posted on 2011-09-03
3
Medium Priority
?
366 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 31

Accepted Solution

by:
hnasr earned 2000 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

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

It’s the first day of March, the weather is starting to warm up and the excitement of the upcoming St. Patrick’s Day holiday can be felt throughout the world.
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
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 …

650 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