+ Reply to Thread
Results 1 to 4 of 4

share workbook issue

  1. #1
    Registered User
    Join Date
    07-20-2018
    Location
    Hong Kong
    MS-Off Ver
    2007
    Posts
    60

    share workbook issue

    Dears,

    I wrote a VBA program which is protected by password and share the workbook. Unfortunately, I got an error when I execute my VBA.

    "Run-time error '1004'
    Unprotect method of Worksheet class failed"



    Please Login or Register  to view this content.

    Oliver

  2. #2
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Arrow

    Hi,

    as here it's very not a mind readers forum so we can't guess which codeline raises the error ! Read the top screen yellow banner …

    Try to unprotect during the execution, who knows …

  3. #3
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,937

    Re: share workbook issue

    Try changing this line

    Please Login or Register  to view this content.
    to

    Please Login or Register  to view this content.
    or possibly name the sheet as in

    Please Login or Register  to view this content.
    Last edited by alansidman; 10-26-2019 at 11:50 AM.
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  4. #4
    Registered User
    Join Date
    07-20-2018
    Location
    Hong Kong
    MS-Off Ver
    2007
    Posts
    60

    Re: share workbook issue

    Dear Alan,

    I tried your suggestion, but the problem still exists. One thing I need to mention is that the workbook is not only password protected, but also have several cells for editing.


    Oliver

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Macro to un-share then re-share OR spell check a hsared workbook Macro?
    By yetibeard in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-04-2018, 06:32 PM
  2. Replies: 1
    Last Post: 07-22-2018, 08:19 AM
  3. [SOLVED] cannot share workbook with macro pulling data from another workbook
    By Ramzes in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-10-2015, 10:32 AM
  4. Replies: 2
    Last Post: 07-29-2013, 12:19 PM
  5. Very wierd issue with document saved on network share
    By johnmani in forum Excel General
    Replies: 3
    Last Post: 02-27-2013, 02:34 PM
  6. Replies: 4
    Last Post: 04-24-2006, 02:00 PM
  7. How to create new workbook and share the workbook through vb script?
    By sam22_blr in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-24-2005, 01:47 AM

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