Missing Menu bar in 2007 not 2003

DCrake

Remembered
Local time
Today, 04:51
Joined
Jun 8, 2005
Messages
8,626
I have created a main menu form in 2003 that has a menubar and it all works fine in 2003, however as soon as I load it up in 2007 the menu bar does not show. Is there any addional settings I need to make to make it visible.

Also I need to be able to hide the ribbon, but as it it written in 2003 how would I do this when run under 2007?

The form is maximizing on activation if this has anything to do with it.

David
 
Dave, its something like customise, your ribbon bar and select add-ins - then you have options to minimize/hide the ribbon, and use your own addin menu bar instead

I was sure I had an email I had sent explaining this to a client, but I cant find it - and I cant load A2007 at the moment.

------------
dont know if you ever change the caption of the access window in A2003 (using API call)- but that doesnt work in A2007 either. I've not looked into a solution for that yet.
 
Thanks Dave,

My client is in Dubia using A2007 on a Vista O/S he has tried removing the ribbon which works but the custom menu bar is missing. As I am using 2003 can't test it.

David
 
tell him to look for addins - I think thats what it is called
 
Sort of sussed it

It was a case of setting the currentProject.Path as a trusted location
Enabled macro content
Customised the Quick launch menu
added Add-ins and selected custom menus.

However I don't think it is spot on there must be an easier way.I don't like the gap it leaves below it and the fact that it says custom menu.

Surely there must be other apps that use custom menus that don't look like this.

David
 

Attachments

  • Add ins.jpg
    Add ins.jpg
    98.9 KB · Views: 277
... I need to be able to hide the ribbon, but as it it written in 2003 how would I do this when run under 2007?

David

David:

This should help:

http://accessjunkie.com/faq_31.aspx

You can disable it for the database by clicking the appropriate setting and it will permanently solve the problem.

I've taken this a step further by having it do this programatically so I don't need to walk my clients through this step each time. Here's how:

First, I have a function in a module somewhere that allows me to programatically set database properties. I found this code on some Microsoft support page:

Code:
Public Sub SetProp(PropName As String, PropVal As Variant, Optional PropType = dbText)
     Dim db As Object
     Dim prp As Object
     Dim strTitle As String
   
     Const PROPERTY_NOT_FOUND As Integer = 3270
   
     On Error GoTo ErrorHandler
   
     Set db = CurrentDb
   
     ' Try to set the property. If it fails, the property does not exist.
     db.Properties(PropName) = PropVal
   
ExitLine:
     db.Close
     Set db = Nothing
     Set prp = Nothing
     Exit Sub
   
ErrorHandler:
     If Err.Number = PROPERTY_NOT_FOUND Then
        ' Create the new property.
        Set prp = db.CreateProperty(PropName, PropType, PropVal)
        db.Properties.Append prp
        Resume Next
     Else
        Resume ExitLine
     End If
   
  End Sub

Ok, now I can set the property I want when the program loads. In my splash screen's On_Open event, I put the following:

Code:
Dim i As Integer

'First I guarantee that I don't see any Access toolbars.
  
For i = 1 To CommandBars.count
CommandBars(i).Enabled = False
Next i

'Then I call my own

Call SetProp("Startupmenubar", "MyNiceToolbar")

That way it shows my nice toolbar instead of the ribbon headache supplied by Access.

SOMETIMES, you need to turn the application on, see the toolbar, THEN the property gets set, and it will take effect the next time you activate the application. That's still much easier than having to tell the client to press shift while opening the application and jump through all the hurdles.

Yes, Access 2007 is a nightmare.

SHADOW
 
can someone take a look at this cut down mdb in Access 2007 and see if the menu bar appears. For the life in me I cannot get it to show.

The only menu bar option that will work in this version is File > Database Window. You will be asked for a password, use Manager.


You see the menu if you use the Bypass key but if you open it up direct you don't

David
 

Attachments

When launched in 2003 no menu appeared.
When launched in 2007 menu appeared along with Database Menu.

Edited the FrmMain to view changes and removed the rem from the hide menu bar and It crashed.

Sorry, but it did not work.

What changes did you actually make apeart from remming the ShowToolBar commands?

David
 

Users who are viewing this thread

Back
Top Bottom