G
Gleam
I have found ths code listed below which gives a method of using sendkeys to
unlock a password protected project. I contains the line
..SendKeys "{TAB}", True ' Tab to locked project
If one has more than two workbooks open how can one be sure that enough tabs
have been performed?
Is there a way of reading the project name so that the code can compare it
with the workbook name?
Sub UnlockVBAProject()
' XL2000, Win2K
With Application
.SendKeys "%{F11}", True ' VBE
.SendKeys "^r", True ' Set focus to Explorer
.SendKeys "{TAB}", True ' Tab to locked project
.SendKeys "~", True ' Enter
.SendKeys "password" ' project password
.SendKeys "~", True ' Enter
End With
End Sub
unlock a password protected project. I contains the line
..SendKeys "{TAB}", True ' Tab to locked project
If one has more than two workbooks open how can one be sure that enough tabs
have been performed?
Is there a way of reading the project name so that the code can compare it
with the workbook name?
Sub UnlockVBAProject()
' XL2000, Win2K
With Application
.SendKeys "%{F11}", True ' VBE
.SendKeys "^r", True ' Set focus to Explorer
.SendKeys "{TAB}", True ' Tab to locked project
.SendKeys "~", True ' Enter
.SendKeys "password" ' project password
.SendKeys "~", True ' Enter
End With
End Sub