PDA

View Full Version : VBA Password Prompt Appears on Exit from Excel



scott56
07-28-2016, 12:45 PM
I have been experiencing an issue where the VBA Password Prompt appears when exiting Excel for workbooks that have a locked VBA project.
16741

For me it is happening on a Win10 / Excel2013 and Win10 / Excel2016 environment. I have searched for and tried a number of possible solutions. See the attached workbook and a step recorder that shows this happening for one of the tests. One interesting difference for the tests that are included to the workbook is in the case where a "pop-up" form is displayed, when closing the VBA password prompt is shown 5 times instead of 3 times on a standard exit from the workbook for the other tests.

Sample Workbook - https://sites.google.com/a/xlautomation.com.au/website/free-downloads/TestVBAPassword%20v2%20Share.xlsm?attredirects=0&d=1
Password to see the code in this workbook...."password"
Step Recorder showing the issue - https://sites.google.com/a/xlautomation.com.au/website/free-downloads/VBA%20Password%20Prompt%20Example.zip?attredirects=0&d=1

I can see from other posts that this problem has appeared over the years and some have resolved it with removing Add-In references, Closing Excel in a certain way none of these are working in my case. It is not a viable option to unprotect the VBA project as the workbooks are shared with others and allowing access to the code would present support issues.

If anyone has further suggestions to resolve this issue please share those back.