Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How do I add a Password?

Hi,

I've got this Workbook_Open code and I'd like to add a password i
order to unable the users to unprotect the sheets.
I just need one password for all the sheets.
Since I don't know how and where to put the password, your help vital.

I enclose the code.

Thank you!
Alex
Bad

Attachment filename: private sub workbook.txt
Download attachment: http://www.excelforum.com/attachment.php?postid=61655
--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default How do I add a Password?

Hi
use somehing like
....
dim wks as worksheet
for each wks in activeworkbook.worksheets
wks.protect password:="yourpassword" 'and the other protect options
you may nee
next
....

--
Regards
Frank Kabel
Frankfurt, Germany


Hi,

I've got this Workbook_Open code and I'd like to add a password in
order to unable the users to unprotect the sheets.
I just need one password for all the sheets.
Since I don't know how and where to put the password, your help

vital.

I enclose the code.

Thank you!
Alex
Bad:

Attachment filename: private sub workbook.txt
Download attachment:
http://www.excelforum.com/attachment.php?postid=616555 ---
Message posted from http://www.ExcelForum.com/


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default How do I add a Password?

Frank,

I tried and tried, but it goes in conflict with the existing protection
code.

Can you have a look to the existing code and let me know where am i wrong?

I'm sure there's too much into it if I add your code.

Thanks
Alex
"Frank Kabel" wrote in message
...
Hi
use somehing like
...
dim wks as worksheet
for each wks in activeworkbook.worksheets
wks.protect password:="yourpassword" 'and the other protect options
you may nee
next
...

--
Regards
Frank Kabel
Frankfurt, Germany


Hi,

I've got this Workbook_Open code and I'd like to add a password in
order to unable the users to unprotect the sheets.
I just need one password for all the sheets.
Since I don't know how and where to put the password, your help

vital.

I enclose the code.

Thank you!
Alex
Bad:

Attachment filename: private sub workbook.txt
Download attachment:
http://www.excelforum.com/attachment.php?postid=616555 ---
Message posted from http://www.ExcelForum.com/




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to retrive password protected worksheet but forgot password? Laurie Excel Worksheet Functions 1 November 19th 09 09:42 PM
how to automate opening a password protected excel file? e.g. a .xls that has a password set in the security tab. Daniel Excel Worksheet Functions 0 June 23rd 05 11:56 PM
bypass password when update linking of password protected file Yan Excel Discussion (Misc queries) 1 February 7th 05 11:29 PM
Excel password but cant hide the sheets before entering password cakonopka[_3_] Excel Programming 1 January 30th 04 06:28 PM
VBa, Password protected sheet fails to get unprotected with the same password Hans Rattink Excel Programming 3 July 28th 03 02:30 PM


All times are GMT +1. The time now is 03:40 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"