+ Reply to Thread
Results 1 to 6 of 6

Remove deeply integrated "Activesheet"Protect Password VBA

  1. #1
    Forum Contributor
    Join Date
    08-12-2013
    Location
    USA
    MS-Off Ver
    Excel 2016
    Posts
    146

    Remove deeply integrated "Activesheet"Protect Password VBA

    So a friend of mine gave me a very large excel spreadsheet with lots of "Microsoft Excel Objects" and "Modules" in the VBA which contain the ThisWorkbook.Protect lines. I'm assuming this is what is causing me problems and re-protecting the sheet once I move to another. Unfortunately its a file I cannot share and was wondering if anyone has had experience with this? He told me the password but its a pain to enter it everytime when I right-click the sheet name to unprotected. I've gone though all the steps and I go to review>unprotected workbook & sheet>password accepted and unlocked then I go to another sheet and do the same but go back and its protected again. I was wondering if there was a way to remove the password protection from the 30ish Modules safely? Or is there another way around this?

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Remove deeply integrated "Activesheet"Protect Password VBA

    Ask him to remove the code that keeps reprotecting the sheets.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Forum Contributor
    Join Date
    08-12-2013
    Location
    USA
    MS-Off Ver
    Excel 2016
    Posts
    146

    Re: Remove deeply integrated "Activesheet"Protect Password VBA

    Quote Originally Posted by shg View Post
    Ask him to remove the code that keeps reprotecting the sheets.
    I wish it was that easy hahaha. He said I'd have to go though all of the lines and remove them...~10000 lines. Do you know how it would re-protect the sheets after?

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Remove deeply integrated "Activesheet"Protect Password VBA

    Please Login or Register  to view this content.
    ... where expression evaluates to a worksheet.

  5. #5
    Forum Contributor
    Join Date
    08-12-2013
    Location
    USA
    MS-Off Ver
    Excel 2016
    Posts
    146

    Re: Remove deeply integrated "Activesheet"Protect Password VBA

    Quote Originally Posted by shg View Post
    Please Login or Register  to view this content.
    ... where expression evaluates to a worksheet.
    So to either remove all .protect/.unprotect lines in the VBA I need to create another that says: Workbook.unprotect Password-"#####" and constantly run the macro? Can I have one that deletes all instances of password protection?

  6. #6
    Forum Expert
    Join Date
    04-01-2013
    Location
    East Auckland
    MS-Off Ver
    Excel 365
    Posts
    1,343

    Re: Remove deeply integrated "Activesheet"Protect Password VBA

    can't you just find and replace in the project however it is that he codes the protection? (I assume it is consistent)

    maybe it is something like

    Please Login or Register  to view this content.
    so find and replace that with nothing ( I mean using the mass find replace functionality so that it takes seconds)
    Last edited by scottiex; 12-08-2015 at 03:39 PM.

+ 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. [SOLVED] If Not ActiveSheet.Range("A1").Value Like "apple" Then MsgBox "Error"
    By HerryMarkowitz in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 02-18-2014, 02:16 PM
  2. [SOLVED] Create a new workbook for every worksheet starting with "E" and password protect
    By Darth Raven in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-06-2014, 09:12 AM
  3. Replies: 3
    Last Post: 03-08-2013, 09:28 AM
  4. [SOLVED] Activate "sorting" feature when worksheets are setup to "password protect" itself
    By nenadmail in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-26-2012, 09:04 PM
  5. [SOLVED] OT I would want protect my sheets of excel from a "password recovery" software... How?
    By -= Luca =- in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-31-2006, 05:10 AM
  6. I would want protect my sheets of excel from a "password recovery" software... How?
    By -= Luca =- in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-30-2006, 09:10 PM
  7. Replies: 1
    Last Post: 06-26-2005, 04:05 AM
  8. [SOLVED] ActiveWorkbook.Protect password:=range("rangename") does not work
    By WimR in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-26-2005, 04:05 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