Results 1 to 3 of 3

Menu Bar Missing, pt.2

Threaded View

  1. #1
    Forum Contributor
    Join Date
    08-29-2012
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    103

    Menu Bar Missing, pt.2

    I was asked to repost this into a new thread. The old thread has a wealth of information so I hate repeating it... Old Link

    So my menu bar is missing completely, formula bar, rows, columns, file bar. This was an unexpected side-effect of some code I was working with in vb.net, however I changed reversed the changes in vb.net and the problem persists. Here is my vb.net code:

      'CODE FOR DISABLING EXCEL FEATURES
        Sub HideAllMenus(app As Excel.Application)
            With app
                .DisplayFormulaBar = False
                .DisplayStatusBar = False
                .CommandBars("Worksheet Menu Bar").Enabled = False
                .CommandBars("Standard").Visible = False
                .CommandBars("Formatting").Visible = False
                If CDbl(.Version) >= 12.0# Then
                    If .ExecuteExcel4Macro("Get.ToolBar(7,""Ribbon"")") Then
                        .ExecuteExcel4Macro("Show.ToolBar(""Ribbon"", False)")
                    End If
                End If
            End With
        End Sub
    
        'CODE FOR DISABLING EXCEL FEATURES
        Sub HideRowColHeadings(wb As Excel.Workbook)
            Dim window As Excel.window
            For Each window In wb.Windows
                window.DisplayHeadings = False
            Next
        End Sub
    And this code to restore it:

    Sub RestoreAllMenus(app As Excel.Application)
            With app
                .DisplayFormulaBar = True
                .DisplayStatusBar = True
                .CommandBars("Worksheet Menu Bar").Enabled = True
                .CommandBars("Standard").Visible = True
                .CommandBars("Formatting").Visible = True
                If CDbl(.Version) >= 12.0# Then
                    .ExecuteExcel4Macro("Show.ToolBar(""Ribbon"", True)")
                End If
            End With
        End Sub
    
        Sub ShowRowColHeadings(wb As Excel.Workbook)
            Dim window As Excel.window
            For Each window In wb.Windows
                window.DisplayHeadings = True
            Next
        End Sub
    The application was working totally fine all week until now for no apparent reason. Now I can't access the menu bar or controls at all. Completely missing! First, I tried correcting it in vb.net and it worked on that one sheet when I ran the application, but as soon as I closed down my application, all other workbooks I load up are missing the bar! I tried using this code in vba using Alt+F11, then Alt+F8 to run it, but nothing happened, nothing at all! EDIT: I added the top line of code and now the FORMULA BAR is displaying but still nothing else. Any help much appreciated: EDIT-2: FYI, when I edit it in vb.net, I can restore all settings, but in Excel, they are gone.

    'VBA Code
    Sub Enable_Menu_Bar()
        
        Application.DisplayFormulaBar = True
        Application.StatusBar = True
        CommandBars("Worksheet Menu Bar").Enabled = True
        CommandBars("Standard").Visible = True
        CommandBars("Formatting").Visible = True
        ActiveWindow.DisplayHeadings = True
    '    Window.DisplayHeadings = True
    End Sub
    Last edited by Taemex; 11-20-2014 at 12:46 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Menu Bar missing!
    By Lionzz in forum Excel General
    Replies: 13
    Last Post: 07-27-2016, 04:55 AM
  2. [SOLVED] Missing Menu
    By Ramzes in forum Excel - New Users/Basics
    Replies: 9
    Last Post: 06-29-2010, 07:59 AM
  3. excel menu missing
    By Euan in forum Excel General
    Replies: 2
    Last Post: 06-19-2006, 03:20 PM
  4. [SOLVED] missing the menu bar
    By uzidengineer in forum Excel General
    Replies: 2
    Last Post: 11-30-2005, 03:45 PM
  5. missing a menu bar
    By uzidengineer in forum Excel General
    Replies: 1
    Last Post: 11-30-2005, 02:40 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1