How do I remove VBA projects in Excel

R

ramunlim

Previous information is:

My excel in 2003 version had two unwanted files piggybacked on each new excel
file I made. I thought that ths would be cured by installing 2007 but still
they are there and on each new file I create. How do I get rid of them.

Luke M said:
Do you have macros enabled? It sound like you might have something encoded in
the VBA for your personal.xls

The personal.xls sheet is what Excel uses to store your personal settings.
If you have a macro written to it, any workbook you open will have these
settings applied. You can open the VBA editor by pressing Alt+F11 to check.

Luke -

It appears that you are right (I can see them as VBA projects when I
AltF11) but for the life of me, I cannot find a way to delete these projects
- can you help?

Dick Myers
 
D

Dave Peterson

What are the names of these files/projects?

Maybe they're not associated with any file--maybe they're associated with excel.
 
R

ramunlim

Each is an excel file - one is personal.xls and the other is book1.xls
However, they come up with each new excel file I create and cannot be
eliminated from the old files. I delete them and they re-appear every time I
open the original excel files.
 
J

Jon Peltier

These are not associated with a new file. These are associated with Excel,
and appear whenever Excel is opened. Both are located in a directory called
XLSTART, either in the Program Files directory under Microsoft Excel, or in
Documents and Settings under Application Data. When starting, Excel will
open any files stored in XLSTART.

Personal.xls is where the macro recorder places macros that you record, and
it must be open to access any of these macros. XLSTART may include other
files, book.xlt and sheet.xlt are templates used when you insert a new
workbook or worksheet. These do not accidentally occur, but are created by a
user who wants some specific formatting and other features to be made
available in new workbooks or worksheets.

Book1.xls was probably placed in XLSTART improperly.

- Jon
 
D

Dave Peterson

Personal.xls is a file that many people use to hold macros that they want
available whenever they open excel.

Most people make sure that this workbook is hidden when they open excel.

If your personal.xls workbook is not hidden, you can open excel, then activate
personal.xls.

Then click on Window|Hide window
Then close excel.
You'll be prompted to save personal.xls (in a hidden state).

This personal.xls file is usually stored in your XLStart folder (location will
vary with version of excel and version of windows and upgrade path).

If you don't have any macros, you can close excel and move or delete that file
from your xlstart folder.

Use windows start button|search to look for XLStart (or personal.xls) and move
the file to a nice backup location (or delete it if you're positive you don't
want it).

As for the book1.xls, please verify that it's really named book1.xls (with that
extension). If it has that extension, then I'd look in that same XLStart folder
for a file named book1.xls. And delete it.

If the workbook is really named book1 (without the extension), then this is
normal. When you start excel, it'll think that you want to create a new
workbook. So it gives you one to start.

========
There are other places these files could be located, but your situation screams
out to look at XLStart first.

But they could be in the folder that is identified here:
Tools|options|general tab|"at startup, open all files in:" folder

Just erase that entry in the dialog--don't delete the folder (well, unless you
don't need anything in that folder).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top