PV Access Ranking Nihon Blog Mura

[Forgot Password] How to Remove VBA (Macro) Passwords in Excel

I forgot my VBA password! Excel Macro (VBA)
The article contains advertisements.

When you try to open a VBA created by someone else, you might encounter a situation where the VBA is password-protected and cannot be viewed.

Or, even if it's VBA that you created yourself, there are cases where you forget the password and can no longer open it.

It appears the VBA project is password protected.

In such cases, you can use this method to unlock it.

You can also refer to these for other password reset methods.

Forgot Password? How to Remove Read-Only (Write Protection) in Excel
If you forgot your Excel password, don’t worry! This article explains how to remove write protection easily by simply changing the file extension. Learn how to unlock read-only mode fast.
Forgot Password] How to remove sheet protection Excel (Excel)
In Excel with "Sheet Protection" enabled, there are times when you absolutely must remove the protection, but the person who set it up has already retired or lost the memo, and you don't know the password. In such cases, is it hopeless? No, ...

Prepare a binary editor

To perform this operation, you need to open a ".bin" file using a binary editor. In most cases, you probably won't have this software, so let's download it first.

If you search for "binary editor" or similar terms, you will find them.

Window Forest

Binary editor

Change the extension to ".zip"

First, please copy the relevant Excel file and create a backup. If you fail in the subsequent operations, there's a possibility it will become impossible to open.

1. As shown in the diagram below, change the Excel file extension from ".xlsm" to ".zip".

Change the extension to zip

2. A warning screen like the one below will appear, so click "Yes."

Change File Extension Warning

3. The Excel file will then change to a ".zip" file.

Excel turned into a zip file.

Extract "vbaProject.bin" from the zip file

Double-click the ".zip" file created above to open it and then open the folder named "xl".

Open an Excel file

2. Copy the "vbaProject.bin" file to another location.

Extract the "vbaProject.bin" file

Process the "vbaProject.bin" file

Open "vbaProject.bin" with the binary editor you downloaded

Open file from binary editor

If ReadOnly is checked, click to uncheck it.

Uncheck ReadOnly

Search for "DPB"

Search for "DPB"

Replace one of the letters in "DPB" with another letter. Pressing the letter keys while holding down Shift will work.

Replace "DPB" with "aPB".

Save and close "vbaProject.bin."

Overwrite the "vbaProject.bin" file

Return the "vbaProject.bin" file to the original ".zip" file folder

Return the "vbaProject.bin" file to its original location

Click on "Copy and Replace."

Select "Copy and Replace"

Open Excel

Change the extension of the processed ".zip" file back to ".xlsm"

Change the file extension from ".zip" to ".xlsm"

Open the Excel file that was being processed.

Excel file

An error message like the following appears when I open Excel. It's okay if the name I just changed appears as an "invalid key."

error message

If you see an error with a different string here, it's highly likely you've made a mistake somewhere, so please start over from the beginning.

Open it, save it immediately, and close Excel.

Save Over

When I open Excel again, the VBA password is removed.

VBA has opened!

Comment

en_USEnglish
Copied title and URL