Note: The other languages of the website are Google-translated. Back to English
Увійти  \/ 
x
or
x
Реєстрація  \/ 
x

or

Як відновити загублений пароль захисту робочого аркуша в Excel?

Ми завжди встановлюємо паролі, щоб захистити деякі важливі робочі аркуші від знищення чи модифікації іншими. Але якщо ви забудете свої паролі, як би ви могли це зробити? На щастя, Excel підтримує деякий код VBA для відновлення втраченого пароля захисту робочого аркуша. Ви можете вирішити цю проблему так:

Відновіть загублений пароль захисту робочого аркуша в Excel за допомогою коду VBA
Додатковий посібник із захисту робочого аркуша ...


Відновіть загублений пароль захисту робочого аркуша в Excel за допомогою коду VBA

Наступний код VBA може допомогти вам швидко скасувати оригінальні паролі на аркуші.

1. Відкрийте робочий аркуш, який був захищений раніше.

2. Утримуйте клавішу ALT + F11 і відкриває Вікно Microsoft Visual Basic для програм.

3. Клацання Insert > Модуліта вставте наступний код у Вікно модуля.

Код VBA: відновити втрачений пароль захисту робочого аркуша

Sub PasswordRecovery()
Dim i As Integer, j As Integer, k As Integer
Dim l As Integer, m As Integer, n As Integer
Dim i1 As Integer, i2 As Integer, i3 As Integer
Dim i4 As Integer, i5 As Integer, i6 As Integer
On Error Resume Next
For i = 65 To 66: For j = 65 To 66: For k = 65 To 66
For l = 65 To 66: For m = 65 To 66: For i1 = 65 To 66
For i2 = 65 To 66: For i3 = 65 To 66: For i4 = 65 To 66
For i5 = 65 To 66: For i6 = 65 To 66: For n = 32 To 126
ActiveSheet.Unprotect Chr(i) & Chr(j) & Chr(k) & _
Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & Chr(i3) & _
Chr(i4) & Chr(i5) & Chr(i6) & Chr(n)
If ActiveSheet.ProtectContents = False Then
MsgBox "One usable password is " & Chr(i) & Chr(j) & _
Chr(k) & Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & _
Chr(i3) & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n)
Exit Sub
End If
Next: Next: Next: Next: Next: Next
Next: Next: Next: Next: Next: Next
End Sub

4. Потім натисніть F5 клавішу, щоб запустити цей код, і з'явиться підказка, натисніть OK щоб закрити його, і ваші паролі захищеного робочого аркуша буде відразу скасовано.

Примітки:

1. За допомогою цього коду ви просто відновлюєте лише один пароль захисту робочого аркуша за раз. Якщо є кілька захищених аркушів, вам потрібно застосовувати цей код по одному.
2. Наведений вище код походить від http://excelzoom.com/2009/08/how-to-recover-lost-excel-passwords/.


Легко захистити кілька робочих аркушів одночасно за допомогою пароля в Excel:

повне г, повне г,, показали, від, номер, XNUMX Захист робочих аркушів корисність Kutools для Excel може допомогти вам захистити декілька робочих листів навалом одним і тим же паролем. Він також надає програму для одночасного зняття захисту з цих аркушів. Завантажте повнофункціональний 30-денний безкоштовний шлях Kutools для Excel зараз!


Статті по темі

Як захистити декілька робочих аркушів одночасно в Excel?

Як зняти захист кількох аркушів одночасно в Excel?


Найкращі інструменти для підвищення продуктивності офісу

Kutools для Excel вирішує більшість ваших проблем і збільшує продуктивність на 80%

  • Повторне використання: Швидко вставте складні формули, діаграми і все, що ви використовували раніше; Шифрувати комірки з паролем; Створити список розсилки та надсилати електронні листи ...
  • Супер формула бар (легко редагувати кілька рядків тексту та формули); Макет читання (легко читати та редагувати велику кількість комірок); Вставте у відфільтрований діапазон...
  • Об’єднати клітинки / рядки / стовпці без втрати даних; Вміст розділених комірок; Об'єднати повторювані рядки / стовпці... Запобігання дублюючим клітинам; Порівняйте діапазони...
  • Виберіть Повторюваний або Унікальний Рядки; Виберіть Пусті рядки (усі клітинки порожні); Супер знахідка та нечітка знахідка у багатьох робочих зошитах; Випадковий вибір ...
  • Точна копія Кілька клітинок без зміни посилання на формулу; Автоматичне створення посилань на кілька аркушів; Вставте кулі, Прапорці та інше ...
  • Витяг тексту, Додати текст, Видалити за позицією, Видаліть пробіл; Створення та друк проміжних підсумків підкачки; Перетворення вмісту комірок та коментарів...
  • Супер фільтр (зберегти та застосувати схеми фільтрів до інших аркушів); Розширене сортування за місяцем / тижнем / днем, частотою та іншим; Спеціальний фільтр жирним, курсивом ...
  • Поєднайте робочі зошити та робочі аркуші; Об’єднати таблиці на основі ключових стовпців; Розділіть дані на кілька аркушів; Пакетне перетворення xls, xlsx та PDF...
  • Понад 300 потужних функцій. Підтримує Office / Excel 2007-2019 та 365. Підтримує всі мови. Простота розгортання на вашому підприємстві чи в організації. Повна функція 30-денної безкоштовної пробної версії. 60-денна гарантія повернення грошей.
вкладка kte 201905

Вкладка Office забезпечує інтерфейс з вкладками для Office і значно спрощує вашу роботу

  • Увімкніть редагування та читання на вкладках у Word, Excel, PowerPoint, Publisher, Access, Visio та Project.
  • Відкривайте та створюйте кілька документів на нових вкладках того самого вікна, а не в нових вікнах.
  • Збільшує вашу продуктивність на 50% та зменшує сотні клацань миші для вас щодня!
дно офісної таблиці
Say something here...
symbols left.
You are guest
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.
  • To post as a guest, your comment is unpublished.
    tirud15 · 29 days ago
    can't insert module after pressing alt +f11 key in vba mode . it is blank. any help
  • To post as a guest, your comment is unpublished.
    thiru · 29 days ago
    can"t insert module . it was blank , after pressing alt + f11 key . any suggestion

  • To post as a guest, your comment is unpublished.
    emshihab · 5 months ago
    Thanks for the solution. I am facing problem running this code. When i run the code, the code is loading and loading. There is nothing happen. What is the problem?
  • To post as a guest, your comment is unpublished.
    Ekram · 5 months ago
    Thanks for the solution. I am facing problem running this code. The code is loading and loading. There is nothing happen. What is the problem?
  • To post as a guest, your comment is unpublished.
    Nutcake · 7 months ago
    Great thanks to you! Can you please advise what I can do if the whole workbook is password protected? 
    • To post as a guest, your comment is unpublished.
      Nutcake · 6 months ago
      Ended up using a password recovery service for that. Tried several, but only one provided actual proof it works, it's called Password-Find. 
  • To post as a guest, your comment is unpublished.
    Jerry · 7 months ago
    Great thanks to you! Can you please advise what I can do if the whole workbook is password protected? 
  • To post as a guest, your comment is unpublished.
    Sri · 9 months ago
    Thank you so much. It worked. Great Work Appreciate you.
  • To post as a guest, your comment is unpublished.
    liamh · 9 months ago
    Can you explain why you only use letters A and B in the check for the first 11 characters, then use characters 32 to 126 for the last one?
  • To post as a guest, your comment is unpublished.
    Sasi · 1 years ago
    I have protected some cells in excel sheet and forgot the password. When i run above code, It's not working. Plz help to resolve it.
  • To post as a guest, your comment is unpublished.
    tiffany.cannagle@gmail.com · 1 years ago
    I have tried, but the module class is not active. Can you help?
  • To post as a guest, your comment is unpublished.
    Ken · 1 years ago
    while i open my protected file, it ask me for the password. then i click Alt-F11, but no VBA window pop up. Please advise how can i reset my password or open the protected file.

    leungchinto888@yahoo.com.hk
  • To post as a guest, your comment is unpublished.
    suranga · 2 years ago
    Thank you so much. Great Work Appreciate you
  • To post as a guest, your comment is unpublished.
    Chris · 2 years ago
    I have lost the password to my Excel workbook. Every time a click to open the file, a pop up box is displayed that the file is protected however the password I enter is always incorrect, then I get a message "the password you supplied is not correct. Veryfied that the caps lock key is off and made sure to use the correct capitalization. I really need to get this file opened. Please help
    • To post as a guest, your comment is unpublished.
      Gustavo · 1 years ago
      Hi, have this problem when I try yo open a Excel file


      did you find any Solution?



      gustnm@hotmail.com
  • To post as a guest, your comment is unpublished.
    Ian · 2 years ago
    Works great, as long as you are using it for the right problem. If you have worksheet protection to stop people editing formulas, etc. then this is the solution. If you have a password on the workbook for privacy (i.e. can't open workbook without password) then you will need to look elsewhere.
  • To post as a guest, your comment is unpublished.
    Franny · 2 years ago
    Thank you so much! It worked. I am running Windows 10 Pro.
  • To post as a guest, your comment is unpublished.
    Steph · 2 years ago
    THANK YOU SO MUCH!
  • To post as a guest, your comment is unpublished.
    Laddy · 2 years ago
    Worked like a charm on 2016, just as expected. Much appreciated.
  • To post as a guest, your comment is unpublished.
    Paula · 2 years ago
    utilizo la macro y se ejecuta pero
    al final no me sale el aviso con la contraseña; qué puedo hacer? gracias!!
  • To post as a guest, your comment is unpublished.
    Chithra · 2 years ago
    you mentioned, open the sheet which was protected before, what dows that mean ?

    I forgot mt workbook password, and without providing the password, alt + f11 is not working, how to break the password please?
    • To post as a guest, your comment is unpublished.
      Heather · 2 years ago
      Same problem here. Running Excel 2016, but file saved was Excel 2006. I can get into "Microsoft Visual Basic for Applications window.", but on the "Insert" tab all the options (including "Module" are greyed out. Now what can I try???
  • To post as a guest, your comment is unpublished.
    Satish · 2 years ago
    thankyou ... very very usefull
  • To post as a guest, your comment is unpublished.
    teri · 2 years ago
    I get an error: Invalid outside procedure. Please help!
  • To post as a guest, your comment is unpublished.
    vittal · 2 years ago
    THANK YOU VERY MUCH FOR CODE
  • To post as a guest, your comment is unpublished.
    Laura Gonçalves · 2 years ago
    Merci beaucoup ça a très bien fonctionné ! je suis sauvée. Merci encore
  • To post as a guest, your comment is unpublished.
    Horton · 3 years ago
    did not work for 2016, just spins and then the 'not responding'. Frustrating.
    • To post as a guest, your comment is unpublished.
      Godfrey · 2 years ago
      Same thing for me: after pressing F5, no response.
  • To post as a guest, your comment is unpublished.
    Paul · 3 years ago
    Finally. Something on the Internet that actually worked! Saved me a ton of time. Thanks!
  • To post as a guest, your comment is unpublished.
    Michael ONI · 3 years ago
    It works like magic. Many thanks.
  • To post as a guest, your comment is unpublished.
    massy.sarti@gmail.com · 3 years ago
    Dear all..i need to unprotect Workbook structure.. Somebody can help me?
  • To post as a guest, your comment is unpublished.
    Arlene · 3 years ago
    How long does it usually take?
    • To post as a guest, your comment is unpublished.
      Jheng · 3 years ago
      after I press the F5 button, the excel file automatically do not respond
  • To post as a guest, your comment is unpublished.
    Kindness · 3 years ago
    how does it take for code to run?
  • To post as a guest, your comment is unpublished.
    shehbaz · 3 years ago
    Thanks a lot. Its work for me.
  • To post as a guest, your comment is unpublished.
    Maha · 3 years ago
    Hi I need your help desparately. I have lost the password to my excel workbook. Every time a click to open the file, a pop up box is displayed that the file is protected however the password I enter is always incorrect, then a get a message "the password you supplied is not correct. Very that the caps lock kep is off and be sure to use the correct capitalization. I really need to get this file opened. Please help
    • To post as a guest, your comment is unpublished.
      Margot · 2 years ago
      Hi, I'm having the same issue. Were you able to somehow recover the file?
  • To post as a guest, your comment is unpublished.
    MESSI · 3 years ago
    It worked. Thanks for the help
  • To post as a guest, your comment is unpublished.
    Ellesig · 3 years ago
    Thanks so much!
  • To post as a guest, your comment is unpublished.
    guest · 3 years ago
    I'm on Excel for Mac, Mac OS High Sierra. This does not work. It does not cancel the password protection. It also does not provide a working "usable" password. Password is always incorrect. Double checked the code for the usual copy-paste script bug that automatically disables End Sub. Pasted this code into a module all by itself.
    • To post as a guest, your comment is unpublished.
      nirvana · 3 years ago
      Wrong, it works for High Sierra, as I tested it 5 min. ago.
  • To post as a guest, your comment is unpublished.
    flj · 3 years ago
    this is a life saver!
  • To post as a guest, your comment is unpublished.
    Ryan west · 3 years ago
    As soon as I press F5 it goes to not responding and I have to close Excel...
    • To post as a guest, your comment is unpublished.
      Jyel · 3 years ago
      I had the same problem. Have you solved this issue?
  • To post as a guest, your comment is unpublished.
    CL · 3 years ago
    This is a life saver! THANK YOU!
  • To post as a guest, your comment is unpublished.
    Weng · 3 years ago
    Thank you for this ♥
  • To post as a guest, your comment is unpublished.
    dianna · 3 years ago
    when i open the excel password protected file, pop up box password appear. tried hold alt+f11, nothing happens. close the password box, mvb appears but could not add module as it grey out. can someone help me please. thanks
  • To post as a guest, your comment is unpublished.
    Usman · 3 years ago
    Brilliant! Done
  • To post as a guest, your comment is unpublished.
    Madhu Joseph · 3 years ago
    I could not believe it... It worked like a wizard..
  • To post as a guest, your comment is unpublished.
    emmakelly · 3 years ago
    You guys can download this remarkable Excel Password Unlocker software which smoothly recover lost excel file and unlock protection from excel file, word document file and access file. Software easily support all Excel versions upto 2016.
  • To post as a guest, your comment is unpublished.
    Tim · 3 years ago
    Hi, Insert module is greyed out!!! Any help would be appriciated
  • To post as a guest, your comment is unpublished.
    tony · 3 years ago
    sorry doesnt works on 2010 .. ı am getting madddd
  • To post as a guest, your comment is unpublished.
    Bob · 3 years ago
    Worked like a charm.
  • To post as a guest, your comment is unpublished.
    Tochi · 3 years ago
    Please everything is greyed in the MS VB application so the insert and module can't be activated in my own.
  • To post as a guest, your comment is unpublished.
    gmnguru · 3 years ago
    Awesome code! Thanks so much!
  • To post as a guest, your comment is unpublished.
    Noob · 3 years ago
    thank you!!!!!!!!!!!!!!! you saved me lol
  • To post as a guest, your comment is unpublished.
    Elaine · 4 years ago
    The instructions were so easy to follow and worked brilliantly. I had locked myself out of a worksheet for months and couldn't remember the password, thank you
  • To post as a guest, your comment is unpublished.
    ja · 4 years ago
    worked Great!