Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Protect Workbook

I have some AutoOpen() routines including workbook protection

Sub AutoOpen(
ActiveWorkbook.Protect ("password"
End Su

When the workbook is protected from the previous close, this macro
actually turns protection off. If it was unprotected from the previous
close, then it turns back on. I can write a closing routine to counter
this, but it seems wierd to have to do this

Does anyone have ideas about this or am I doind something wrong

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 77
Default Protect Workbook

Hi

I have noticed this wierd behavior where protect acts
as a toggle in Excel 2002 as well. Why I don't know.

The only workaround I have found is to unprotect first,
then protect. This always seems to work correctly then.

ActiveWorkbook.Unprotect ("password")
ActiveWorkbook.Protect ("password")

HTH

KenM


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
Protect workbook Jeevan Excel Discussion (Misc queries) 2 April 20th 09 07:25 PM
Protect Workbook tdw Excel Discussion (Misc queries) 1 January 8th 09 08:39 PM
Protect Workbook andy62 Excel Worksheet Functions 4 July 9th 07 09:25 PM
Protect Workbook Vs Protect Sheet Poor_pakistani New Users to Excel 4 May 25th 06 02:06 PM
Protect Workbook Pedro Mestre Excel Discussion (Misc queries) 1 April 6th 06 03:49 PM


All times are GMT +1. The time now is 04:57 AM.

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"