Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Programmatically unlocking a project

47 views
Skip to first unread message

Paul Sardella

unread,
Jun 5, 2001, 8:33:19 PM6/5/01
to
Hi.

Is it possible to programmatically unlock a password protected project
for viewing?

TIA
Paul

Tim Zych

unread,
Jun 6, 2001, 10:54:03 AM6/6/01
to
From what I've read, SendKeys is required.

Unlocking a VBA Project with this sample worked for me; this was run from a
command button from another workbook in one Excel instance so it will
probably have to be customized.

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


"Paul Sardella" <PSar...@cheerful.com> wrote in message
news:3B1D7A4F...@cheerful.com...

Joe McArthur

unread,
Jun 5, 2001, 11:00:30 PM6/5/01
to
Paul Sardella wrote in message <3B1D7A4F...@cheerful.com>...

>Hi.
>
>Is it possible to programmatically unlock a password protected project
>for viewing?

No.


0 new messages