2013年6月6日 星期四

Removing an Excel VBA password – using a Hex editor

Open your chosen workbook file (.xls or .xla file) in the hex editor. It will look like the following;




The XVI32 Hex editor

Now search for the Text string “DPB” and change it to “DPx” (simply type over the value).




Search for text string "DPB"


Completed search


Change from DPB to DPx

Save the file over the top of the existing workbook and close.


Save protection settings

Now, open the workbook in Excel and click OK until the workbook is open (you may receive a couple of VBA errors on the way). Press ALT+F11 to open the Visual Basic Project window, From the Tools menu, choose the command VBAProject Properties, navigate to the Protection tab, and change the password but do not remove it (note the new password).

Save the workbook, close, and re-open.

Once open, press ALT+F11 and enter the new password.

Finally, choose Tools -> VBAProject Properties, navigate to the Protection tab, and remove the password.

Save the workbook.



沒有留言:

張貼留言