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

Hi

I have a workbook I want to send to other users. This
workbook has protected worksheets. The worksheets have to
be password protected.

How do I create a macro which will unprotect and after
completed the task protect the worksheet without asking
the user for the password I have set.

Regards

Sham


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Protected Worksheets

Look in excel help at the protect and unprotect method.

If using xl2000 or earlier, you can set the userinterfaceonly property to
true and your macro can manipulate the worksheet. In xl2002 and later, you
have to supply the password to set this. You would include the password in
your code. Then protect the project in the VBE so the user can not see the
code.

--
Regards,
Tom Ogilvy

"Shamsul Islam" wrote in message
...
Hi

I have a workbook I want to send to other users. This
workbook has protected worksheets. The worksheets have to
be password protected.

How do I create a macro which will unprotect and after
completed the task protect the worksheet without asking
the user for the password I have set.

Regards

Sham




  #3   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Protected Worksheets

How do you include the password in the code?

-----Original Message-----
Look in excel help at the protect and unprotect method.

If using xl2000 or earlier, you can set the

userinterfaceonly property to
true and your macro can manipulate the worksheet. In

xl2002 and later, you
have to supply the password to set this. You would

include the password in
your code. Then protect the project in the VBE so the

user can not see the
code.

--
Regards,
Tom Ogilvy

"Shamsul Islam"

wrote in message
...
Hi

I have a workbook I want to send to other users. This
workbook has protected worksheets. The worksheets have

to
be password protected.

How do I create a macro which will unprotect and after
completed the task protect the worksheet without asking
the user for the password I have set.

Regards

Sham




.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Protected Worksheets

Activesheet.Protect Password:="ABCD"

--
Regards,
Tom Ogilvy


wrote in message
...
How do you include the password in the code?

-----Original Message-----
Look in excel help at the protect and unprotect method.

If using xl2000 or earlier, you can set the

userinterfaceonly property to
true and your macro can manipulate the worksheet. In

xl2002 and later, you
have to supply the password to set this. You would

include the password in
your code. Then protect the project in the VBE so the

user can not see the
code.

--
Regards,
Tom Ogilvy

"Shamsul Islam"

wrote in message
...
Hi

I have a workbook I want to send to other users. This
workbook has protected worksheets. The worksheets have

to
be password protected.

How do I create a macro which will unprotect and after
completed the task protect the worksheet without asking
the user for the password I have set.

Regards

Sham




.



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
Protected WorkSheets William Wolfe Excel Discussion (Misc queries) 1 June 1st 09 09:41 PM
Groups and Protected Worksheets - know if protected mjones Excel Discussion (Misc queries) 8 April 25th 08 07:43 PM
Protected worksheets Nell Excel Discussion (Misc queries) 1 May 30th 06 12:17 PM
Protected Worksheets Nikki Patel Excel Worksheet Functions 0 April 22nd 05 08:49 PM
Sorting protected worksheets Drr Excel Discussion (Misc queries) 1 December 3rd 04 08:13 AM


All times are GMT +1. The time now is 03:18 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"