+ Reply to Thread
Results 1 to 5 of 5

Protecting shared workbooks

  1. #1
    Duffer
    Guest

    Protecting shared workbooks

    I have been trying to find something like my problem in the KB, but no luck.
    Here goes:
    I have a shared workbook in which I have protected a worksheet and a macro
    attached to a graphic. I wrote code that will unprotect the worksheet while
    the macro is running, then password protect the sheet again as the macro is
    closing down.
    However, once I share the workbook, I can't run the macro! Is there any way
    I can protect a sheet in a shared workbook yet still run a macro on it??
    Thanking you in advance

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Quote Originally Posted by =?Utf-8?B?RHVmZmVy?=
    I have been trying to find something like my problem in the KB, but no luck.
    Here goes:
    I have a shared workbook in which I have protected a worksheet and a macro
    attached to a graphic. I wrote code that will unprotect the worksheet while
    the macro is running, then password protect the sheet again as the macro is
    closing down.
    However, once I share the workbook, I can't run the macro! Is there any way
    I can protect a sheet in a shared workbook yet still run a macro on it??
    Thanking you in advance

    Hi,

    If all you want is to prevent the users from view or changing the macro, you can do so easily. Open the VBE (Visual Basic Eidtor) Select Tools from the Menu.
    Under Tools you will see "VBA Project Properties...". Click on this. You will then see the Project Properties Dialog. Click on the tab labeled "Protection". On this page there should be a checkbox label "Lock Project for Viewing". This can then be password protected so only you can make changes or view the code.

    Best,
    Leith Ross

  3. #3
    Dave Peterson
    Guest

    Re: Protecting shared workbooks

    There are somethings that you can't do in a shared workbook.

    One of the things you can't change is the protection of a worksheet.



    Duffer wrote:
    >
    > I have been trying to find something like my problem in the KB, but no luck.
    > Here goes:
    > I have a shared workbook in which I have protected a worksheet and a macro
    > attached to a graphic. I wrote code that will unprotect the worksheet while
    > the macro is running, then password protect the sheet again as the macro is
    > closing down.
    > However, once I share the workbook, I can't run the macro! Is there any way
    > I can protect a sheet in a shared workbook yet still run a macro on it??
    > Thanking you in advance


    --

    Dave Peterson

  4. #4
    tfarabaugh
    Guest

    RE: Protecting shared workbooks

    I have been trying to solve a problem and it sounds like you may have the
    solution. I want to create code that automatically unprotects the workbook
    and worksheets anytime a macro is run and seals them back up when it is
    completed. There are several hundered macros in the workbook and I do not
    want to have to enter unprotect language at the beginning of each macro. Do
    you know of a way to have it unprotect whenever a macro of any kind is run?

    "Duffer" wrote:

    > I have been trying to find something like my problem in the KB, but no luck.
    > Here goes:
    > I have a shared workbook in which I have protected a worksheet and a macro
    > attached to a graphic. I wrote code that will unprotect the worksheet while
    > the macro is running, then password protect the sheet again as the macro is
    > closing down.
    > However, once I share the workbook, I can't run the macro! Is there any way
    > I can protect a sheet in a shared workbook yet still run a macro on it??
    > Thanking you in advance


  5. #5
    tfarabaugh
    Guest

    RE: Protecting shared workbooks

    I have been trying to solve a problem and it sounds like you may have the
    solution. I want to create code that automatically unprotects the workbook
    and worksheets anytime a macro is run and seals them back up when it is
    completed. There are several hundered macros in the workbook and I do not
    want to have to enter unprotect language at the beginning of each macro. Do
    you know of a way to have it unprotect whenever a macro of any kind is run?

    "Duffer" wrote:

    > I have been trying to find something like my problem in the KB, but no luck.
    > Here goes:
    > I have a shared workbook in which I have protected a worksheet and a macro
    > attached to a graphic. I wrote code that will unprotect the worksheet while
    > the macro is running, then password protect the sheet again as the macro is
    > closing down.
    > However, once I share the workbook, I can't run the macro! Is there any way
    > I can protect a sheet in a shared workbook yet still run a macro on it??
    > Thanking you in advance


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1