Startup Errors In Excel

This page describes how to diagnose and fix errors that may occur during start up:-

Isolate The Scope Of The Problem

The first step in any sort of troubleshooting is to isolate the scope of the problem. Does the problem occur only with a specific workbook? If so, you can focus your efforts on determining what is wrong with that specific file. Possible causes may be that the workbook file has become corrupted or is nearing a corrupt state. Or, it might be related to code in the workbook that automatically executes when the workbook is opened (via either an Auto_Open procedure or the workbook's Workbook_Open event procedure in the ThisWorkbook module.

Start Excel In Safe Mode

When you run Excel in Safe Mode, Excel does not open add-ins or other startup files. It is a clean no-frills mode of operation with many options unavailable. To run Excel in Safe Mode, go to the Windows Start menu, choose Run, and enter

Excel.exe /safe

You may need to enter the entire path to Excel:

"C:\Program Files\Microsoft Office 2007\Office12\Excel.exe" /safe

Of course, your actual path may be different that what is shown above. If Excel does start in Safe Mode, the cause of the problem is likely to be a corrupt or otherwise misbehaving add-in or other start up file. To test this, move all your add-ins to another folder. Then, from the Tools menu, choose Options, and clear the setting for Alternate Startup Location on the General tab. In later versions of Excel, this setting is labelled At startup, open all files in:. Under normal operation, Excel will automatically open all the files that are contained in the folder specified in this option. If this setting is cleared, those files will not be opened. After clearing that setting, close Excel and restart it normally. If Excel starts, then the problem lies in one of the files in the alternate startup folder.

Re-register Excel With Windows

You can use this method to cause Excel to rewrite all of its configuration data in the registry. This effectively sets Excel back to the "factory defaults". From the Windows Start menu, choose Run, and enter:

Excel.exe /UnregServer

As before, you may have to use the full file name rather than just Excel.exe. After you have done this, repeat it but change /UnregServer to /RegServer. When you issue these commands, Excel will start, manipulate its configuration data in the system registry, and then close. If you receive a Success message on the /RegServer, try to start normally. If Excel starts properly, that means there was an invalid entry in the registry. No further action is required.

Start Excel Without Menu And CommandBar Customization

A frequent cause of startup problems is a bloated or corrupt xlb file. Excel stores custom menu and commandbar setting in a file with an .xlb extension. The actual name and location of the xlb file depends on your version of Excel and your version of Windows. Run a Window Search (choose Search from the Windows Start Menu) and search for *.xlb. If one or more of these files are found, move them to another location, and then start Excel. If Excel starts normally, the xlb file is the cause of the problem. There is no way to edit for fix the xlb file. (Microsoft has never released its file format.) About all you can do is start with a new xlb file. There is no way to recover the old one, so your menu item and command bar customizations will be lost.

Start Excel Without Add-Ins

Start Excel in Safe Mode as described above. Then, choose Add-Ins from the Tools menu. Make a note of which add-ins are checked. Uncheck each add-in, starting Excel normally after unchecking each add-in. When Excel starts without error, the most recently unchecked add-in is probably the source of your errors. You may leave that add-in unchecked if you do not need it, or you may contact the author or vender for an updated, fixed version.

Start Excel Without COM Add-Ins

Starting Excel without COM Add-Ins is a two step process. First, start Excel in Safe Mode as described above. If you do not see the COM Add-Ins... item on your Tools menu, press ALT F11 to display the VBA Editor, press CTRL G to display the Immediate window, and enter the following and press ENTER.

Application.CommandBars.FindControl(ID:=30007).Controls.Add ID:=3754

This will add the COM Add-Ins... item to your Tools menu. Switch back to Excel, go to the Tools and click the COM Add-Ins... item. In that dialog, uncheck each item that is checked. Close and restart Excel normally. If Excel starts without error, then one of the COM Add-Ins that you uncheck was causing the problem. You should contact the author or vendor of the COM Add-In for a fixed version.

If Excel does not start normally, you must change some System Registry values. With Excel closed, click the Windows Start menu and choose Run. There, enter RegEdit and click OK. This will open the Registry Editor. You need to be extremely careful when editing registry entries. If you change or delete the wrong key, an application may not start or may not behave as expected. In the worst case, Windows itself will not start. Moreover, you are working "live" with the registry. There is no "undo" function and you cannot exit without saving. Once you change a value, it is changed with no way to automatically restore its value.

The registry data is presented in a "tree view" on the left side of the screen. You open or close "nodes" of the tree by clicking the plus signs next to the little folder icons. To start, completely collapse all expanded nodes. Then click the HKEY_LOCAL_MACHINE node. Within that, expand Software and within that expand Microsoft then Office. Under Office locate and expand the AddIns node. There may be zero or more items under the AddIns node. For each add in listed in the AddIns node, click it in the tree view. You will see named values in the right pane of the window. Locate the LoadBehavior value, double click it and change the value data to 0 and click OK. Do this for each addin. You can now close the Registry Editor.

Now try to start Excel normally. If it starts, then one of the COM Add-Ins in the registry caused the problem. Contact the author or vendor of the COM Add-In to get a fixed version.

Run Detect And Repair

Open Excel in Safe Mode as described above. On the help menu, choose Detect And Repair. This will cause Excel to run some diagnostic procedures and attempt to fix a corrupted environment. You may be asked to restart Excel or perhaps even restart Windows. You may need to provide your Office installation CD. After Detect and Repair is completed, close and restart Excel normally. If it starts then Detect and Repair was successsful.


Popular posts from this blog

The install4j wizard could not find a Java Runtime Environment on your system. Please locate a suitable JRE...

Clients Unable to update - "Cached cookie has expired or new PID is available"

Java Control Panel Icon "Application Not Found"