Does anybody know why my VBA Project would ask for a password when closing. This presents a problem, because I can't give the password out to people or it defeats the whole purpose of protecting the project.
Can anyone help?
It's asking for the password that I used to protect the project. There are NO hidden sheets and I don't use the "beforeclose" event. I do however hide the row and column headers and the tabs and use the User Form to navigate through the project.
On occasion the project also appears twice in the explorer panel. Is there any explanation for this?
Les in Toronto
there are different kinds of passwords
access to the workbook
structure of the workbook
to be sure for 100%: please confirm you are talking about the last one !? (I know you wrote "VBA-project" but sometimes people use such terms arbitrarely)
the only reason I can see to ask a password for the project is, that you are trying (by code) to change something of its contents
or your project might be corrupt ? It is very easy to corrupt a macro module - especially when making lots of changes during development.
A way of "cleaning" the code is to copy/paste it into Notepad (not Word), delete the old module, then copy/paste the code back into a new module.
This also refers to worksheets - so, with a big project, at some late stage it is a good idea to remake everything starting from a new workbook and copy/pasting formats & formulas (ie. contents, not complete sheets) to new sheets.