Aug 08 2020 04:10 AM
Hi team need support to unprotect my sheet which is password protected and forgot the password
Aug 08 2020 11:33 AM
Aug 10 2020 12:11 PM
Hello @vedangbapna This really should be in the Excel community conversation so I'm going to move it there to increase your chances of getting a response.
Aug 10 2020 12:25 PM
'CAUTION only to be used for your own Excel sheets!
Option Explicit
Sub GetPass()
Const a = 65, b = 66, c = 32, d = 126
Dim i#, j#, k#, l#, m#, n#, o#, p#, q#, r#, s#, t#
With ActiveSheet
If .ProtectContents Then
On Error Resume Next
For i = a To b
For j = a To b
For k = a To b
For l = a To b
For m = a To b
For n = a To b
For o = a To b
For p = a To b
For q = a To b
For r = a To b
For s = a To b
For t = c To d
.Unprotect Chr(i) & Chr(j) & Chr(k) & Chr(l) & Chr(m) & _
Chr(n) & Chr(o) & Chr(p) & Chr(q) & Chr(r) & Chr(s) & Chr(t)
Next t
Next s
Next r
Next q
Next p
Next o
Next n
Next m
Next l
Next k
Next j
Next i
MsgBox "Finished"
End If
End With
End Sub
For any irresponsible action with this code, by any user, cannot and will not be responsible.
Nikolino
I know I don't know anything (Socrates)
* Kindly Mark and Vote this reply if it helps please, as it will be beneficial to more Community members reading here.
* Beware of scammers posting fake support numbers here.
Feb 17 2021 08:24 AM
Feb 17 2021 08:36 AM
Feb 28 2021 11:15 PM
Feb 28 2021 11:39 PM
Mar 05 2021 04:39 AM
If you are using Excel 2010 or older, you can unlock a sheet with a password with the following steps:
You can follow this website to no more: https://unboxstop.com/how-to-unprotect-excel-sheet-without-password/
Mar 05 2021 06:21 AM
The code is the same that I sent, just in a different sequence.
The instructions as well as the same.
I don't see any difference, not even in the approach.
Anyway, twice is maybe better.:)
Thanks for your additional help, hope we could help the user with it too.:)
Nikolino
I know I don't know anything (Socrates)
Mar 05 2021 06:53 AM
Simple Solution for me ~ Forgot password worksheet (multiple worksheets in workbook)
Copy sheet into New Tab, Paste so looks exactly like sheet copied (password protect did not copy over to new sheet), double check matches data in prev sheet. Delete original sheet and rename copied one same as original. Password Protect this new sheet (if you wish) making sure you 'write it down' ; - )
Hope works for you!
Mar 10 2021 07:48 AM
Mar 10 2021 09:51 AM
Mar 31 2021 12:36 AM
Apr 11 2021 08:36 AM
@NikolinoDE I have a file of one sheet that I would like to unlock, could you help me with that please?
Apr 12 2021 01:55 AM
Hi Nikolino, I can see you have been able to assist with Excel Spreadsheets with forgotten unprotect passwords. I have the same issue as I created a spreadsheet months ago, have not looked at it since and I've now forgotten the password. Would you be able to assist with recovering the password?
Thanks in advance
Jim
Apr 12 2021 04:51 AM
Help for self-help
For some worksheets it can take a whole day, sometimes more.
But in the end, I was able to decipher all worksheets 99% of the time.
If it is a matter of removing (not retrieving) a Worksheet password, the following code may be used:
In a common Module we paste the following code that removes the code from the activated sheet:
Code:
'CAUTION!! Recommended only for proprietary Excel sheets!
Option Explicit
Sub GetPass()
Const a = 65, b = 66, c = 32, d = 126
Dim i#, j#, k#, l#, m#, n#, o#, p#, q#, r#, s#, t#
With ActiveSheet
If .ProtectContents Then
On Error Resume Next
For i = a To b
For j = a To b
For k = a To b
For l = a To b
For m = a To b
For n = a To b
For o = a To b
For p = a To b
For q = a To b
For r = a To b
For s = a To b
For t = c To d
.Unprotect Chr(i) & Chr(j) & Chr(k) & Chr(l) & Chr(m) & _
Chr(n) & Chr(o) & Chr(p) & Chr(q) & Chr(r) & Chr(s) & Chr(t)
Next t
Next s
Next r
Next q
Next p
Next o
Next n
Next m
Next l
Next k
Next j
Next i
MsgBox "Finished"
End If
End With
End Sub
The time it will take depends to a large extent on the power of the computer.
Nikolino
Apr 12 2021 01:24 PM
Apr 12 2021 01:27 PM
@Patrick2788 Could you elaborate?
Apr 12 2021 03:02 PM
This approach still works although I haven't tested it recently.
Save the workbook under a new name but use Save as Type "Excel 97-2003"
That operation in your new workbook will have lost all features used by Excel versions after Excel 2003.
You then need access to a computer running a version of Excel before Excel 2016 and preferably as early as 2007.
Open your file on the computer running the old version of Excel.
Open also the file I attach to this post. That file can run on later versions of Excel but doesn't work on Excel 365, or Excel 2019, or 2016. I think it might work with a bit of a 'glitch' on 2013. It does work on 2012 and before.
I wrote an explanatory document on including the code used this in Word and I attach that for your assistance.
You can also copy the allinternalpasswords VBA code I wrote in 2002 from:
McGimpsey & Associates : Excel : Remove internal XL passwords
That code will find a password that opens any number of hidden sheets or protected structure.
The disadvantage is that you lose all features from later versions of Excel but you will generally, at least, have back access to all your data and that, indeed, might well be your lifesaver.
Old versions of Excel are still available on Ebay etc. But they really need installing on a computer without any later versions of Excel on it or using a Virtual machine approach.
Hope that helps. Sorry I haven't tested it as I don't have access to an ancient version of Excel at present and don't run a Virtual Machine.
Norman Harker