Macro to Protect workbook using a password

Giganews Newsgroups
Subject: Macro to Protect workbook using a password
Posted by:  PCLIVE (pcli…@livenet.net)
Date: Tue, 14 Oct 2003

I know this would be a little unorthodox, but I currently have a macro that
will unprotect a workbook including a password.  The line is as follows:

ActiveWorkbook.Unprotect (password)

I also want a macro that will do just the opposite, including the password.
Is this possible?  I've tried the following with no luck.

ActiveWorkbook.Protect (password), Structure:=True, Windows:=True

Replies