版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡介
1、如果您需要使用本文檔,請(qǐng)點(diǎn)擊下載按鈕下載!Excel工作表保護(hù)密碼清除1,打開需要解除保護(hù)的EXCEL工作表;2,選擇工具-宏-錄制新宏-輸入名字如:aa;3,停止錄制(這樣得到一個(gè)空宏);4,工具-宏-宏,選aa,點(diǎn)編輯按鈕;5,刪除窗口中的所有字符(只有幾個(gè)),替換為下面的內(nèi)容:(復(fù)制吧);6,關(guān)閉編輯窗口;7,工具-宏-宏,選AllInternalPasswords,運(yùn)行,確定兩次,等2分鐘,再確定.OK,舊的密碼自動(dòng)提示,工作表也自動(dòng)解除保護(hù)了。 內(nèi)容如下:=Public Sub AllInternalPasswords() Breaks worksheet and workbook
2、structure passwords. Bob McCormick probably originator of base code algorithm modified for coverage of workbook structure / windows passwords and for multiple passwords Norman Harker and JE McGimpsey 27-Dec-2002 (Version 1.1) Modified 2003-Apr-04 by JEM: All msgs to constants, and eliminate one Exit
3、 Sub (Version 1.1.1) Reveals hashed passwords NOT original passwords Const DBLSPACE As String = vbNewLine & vbNewLine Const AUTHORS As String = DBLSPACE & vbNewLine & _ Adapted from Bob McCormick base code by & _ 1 / 10如果您需要使用本文檔,請(qǐng)點(diǎn)擊下載按鈕下載!Norman Harker and JE McGimpsey Const HEADER As String = AllI
4、nternalPasswords User Message Const VERSION As String = DBLSPACE & Version 1.1.1 2003-Apr-04 Const REPBACK As String = DBLSPACE & Please report failure & _ to the gramming newsgroup. Const ALLCLEAR As String = DBLSPACE & The workbook should & _ now be free of all password p
5、rotection, so make sure you: & _ DBLSPACE & SAVE IT NOW! & DBLSPACE & and also & _ DBLSPACE & BACKUP!, BACKUP!, BACKUP! & _ DBLSPACE & Also, remember that the password was & _ put there for a reason. Dont stuff up crucial formulas & _ or data. & DBLSPACE & Access and use of some data & _ may be an o
6、ffense. If in doubt, dont. Const MSGNOPWORDS1 As String = There were no passwords on & _ sheets, or workbook structure or windows. & AUTHORS & VERSION Const MSGNOPWORDS2 As String = There was no protection to & _ workbook structure or windows. & DBLSPACE & _ Proceeding to unprotect sheets. & AUTHORS
7、 & VERSION Const MSGTAKETIME As String = After pressing OK button this & _ will take some time. & DBLSPACE & Amount of time & _ depends on how many different passwords, the & _ passwords, and your computers specification. & DBLSPACE & _ Just be patient! Make me a coffee! & AUTHORS & VERSION 2 / 10如果
8、您需要使用本文檔,請(qǐng)點(diǎn)擊下載按鈕下載!Const MSGPWORDFOUND1 As String = You had a Worksheet & _ Structure or Windows Password set. & DBLSPACE & _ The password found was: & DBLSPACE & $ & DBLSPACE & _ Note it down for potential future use in other workbooks by & _ the same person who set this password. & DBLSPACE & _ No
9、w to check and clear other passwords. & AUTHORS & VERSION Const MSGPWORDFOUND2 As String = You had a Worksheet & _ password set. & DBLSPACE & The password found was: & _ DBLSPACE & $ & DBLSPACE & Note it down for potential & _ future use in other workbooks by same person who & _ set this password. &
10、 DBLSPACE & Now to check and clear & _ other passwords. & AUTHORS & VERSION Const MSGONLYONE As String = Only structure / windows & _ protected with the password that was just found. & _ ALLCLEAR & AUTHORS & VERSION & REPBACK Dim w1 As Worksheet, w2 As Worksheet Dim i As Integer, j As Integer, k As
11、Integer, l As Integer Dim m As Integer, n As Integer, i1 As Integer, i2 As Integer Dim i3 As Integer, i4 As Integer, i5 As Integer, i6 As Integer Dim PWord1 As String Dim ShTag As Boolean, WinTag As BooleanApplication.ScreenUpdating = False With ActiveWorkbook 3 / 10如果您需要使用本文檔,請(qǐng)點(diǎn)擊下載按鈕下載!WinTag = .Pr
12、otectStructure Or .ProtectWindows End With ShTag = False For Each w1 In Worksheets ShTag = ShTag Or w1.ProtectContents Next w1 If Not ShTag And Not WinTag Then MsgBox MSGNOPWORDS1, vbInformation, HEADER Exit Sub End If MsgBox MSGTAKETIME, vbInformation, HEADER If Not WinTag Then MsgBox MSGNOPWORDS2,
13、 vbInformation, HEADER Else On Error Resume Next Do dummy do loop 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 With ActiveWork
14、book .Unprotect Chr(i) & Chr(j) & Chr(k) & _ Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & _ 4 / 10如果您需要使用本文檔,請(qǐng)點(diǎn)擊下載按鈕下載!Chr(i3) & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) If .ProtectStructure = False And _ .ProtectWindows = False Then PWord1 = Chr(i) & Chr(j) & Chr(k) & Chr(l) & _ Chr(m) & Chr(i1) & Chr(i2) & C
15、hr(i3) & _ Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) MsgBox Application.Substitute(MSGPWORDFOUND1, _ $, PWord1), vbInformation, HEADER Exit Do Bypass all for.nexts End If End With Next: Next: Next: Next: Next: Next Next: Next: Next: Next: Next: Next Loop Until True On Error GoTo 0 End If If WinTag And No
16、t ShTag Then MsgBox MSGONLYONE, vbInformation, HEADER Exit Sub End If On Error Resume Next For Each w1 In Worksheets Attempt clearance with PWord1 5 / 10如果您需要使用本文檔,請(qǐng)點(diǎn)擊下載按鈕下載!w1.Unprotect PWord1 Next w1 On Error GoTo 0 ShTag = False For Each w1 In Worksheets Checks for all clear ShTag triggered to 1
17、if not. ShTag = ShTag Or w1.ProtectContents Next w1 If ShTag Then For Each w1 In Worksheets With w1 If .ProtectContents Then On Error Resume Next Do Dummy do loop 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
18、 To 66: For i4 = 65 To 66 For i5 = 65 To 66: For i6 = 65 To 66: For n = 32 To 126 .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 Not .ProtectContents Then PWord1 = Chr(i) & Chr(j) & Chr(k) & Chr(l) & _ 6 / 10如果您需要使用本文
19、檔,請(qǐng)點(diǎn)擊下載按鈕下載!Chr(m) & Chr(i1) & Chr(i2) & Chr(i3) & _ Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) MsgBox Application.Substitute(MSGPWORDFOUND2, _ $, PWord1), vbInformation, HEADER leverage finding Pword by trying on other sheets For Each w2 In Worksheets w2.Unprotect PWord1 Next w2 Exit Do Bypass all for.ne
20、xts End If Next: Next: Next: Next: Next: Next Next: Next: Next: Next: Next: Next Loop Until True On Error GoTo 0 End If End With Next w1 End If MsgBox ALLCLEAR & AUTHORS & VERSION & REPBACK, vbInformation, HEADER End Sub=Excel表格密碼保護(hù)的解除方法表格受密碼保護(hù)時(shí),我們修改數(shù)據(jù)Excel彈出“您試圖更改的單元格或圖表受保護(hù),因而是只讀的。若要修改受保護(hù)單元格或圖表,請(qǐng)先使
21、用撤消工作表保護(hù)命令(在審閱選項(xiàng)卡的更改組中)來取消保護(hù)??赡軙?huì)提示您輸入密碼。這時(shí)候我們可以用VBA宏代碼破解法來破解表格保護(hù)密碼:第一步:打開該文件,先解除默認(rèn)的“宏禁用”狀態(tài),方法是點(diǎn)擊工具欄下的“選項(xiàng)”狀態(tài)按鈕,打開“Microsoft Office安全選項(xiàng)”窗口,選擇其中的“啟用此內(nèi)容”,“確定”。再切換到“視圖”選項(xiàng)卡,點(diǎn)擊“宏”“錄制宏”,出現(xiàn)“錄制新宏”窗口,在“宏名”定義一個(gè)名稱為:PasswordBreaker,點(diǎn)擊“確定”退出;第二步:再點(diǎn)擊“宏”“查看宏”,選擇“宏名”下的“PasswordBreaker”并點(diǎn)擊“編輯”,打開“Microsoft Visual Basi
22、c”編輯器,用如下內(nèi)容替換右側(cè)窗口中的所有代碼:8 / 10如果您需要使用本文檔,請(qǐng)點(diǎn)擊下載按鈕下載!Sub PasswordBreaker()Dim i As Integer, j As Integer, k As IntegerDim l As Integer, m As Integer, n As IntegerDim i1 As Integer, i2 As Integer, i3 As IntegerDim i4 As Integer, i5 As Integer, i6 As IntegerOn Error Resume NextFor i = 65 To 66: For j = 65 To 66: For k = 65 To 66For l = 65 To 66: For m = 65 To 66: For i1 = 65 To 66For i2 = 65 To 66: For i3 = 65 To 66: For i4 = 65 To 66For i5 = 65 To 66: For i6 =
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。
最新文檔
- 企業(yè)向員工借款合同書
- 甘孜職業(yè)學(xué)院《初等數(shù)論理論教學(xué)》2023-2024學(xué)年第二學(xué)期期末試卷
- 物業(yè)管理服務(wù)合同范本
- 安置就業(yè)協(xié)議書范文
- 貨物運(yùn)輸合作協(xié)議范本
- 建筑渣土運(yùn)輸處置合同年
- 山西財(cái)貿(mào)職業(yè)技術(shù)學(xué)院《數(shù)學(xué)能力與思維(進(jìn)階)》2023-2024學(xué)年第二學(xué)期期末試卷
- 東南大學(xué)《數(shù)學(xué)教學(xué)軟件與應(yīng)用》2023-2024學(xué)年第二學(xué)期期末試卷
- 工程質(zhì)量協(xié)議書年
- OEM合作協(xié)議oem代工協(xié)議書
- 王崧舟:學(xué)習(xí)任務(wù)群與課堂教學(xué)變革 2022版新課程標(biāo)準(zhǔn)解讀解析資料 57
- 招投標(biāo)現(xiàn)場(chǎng)項(xiàng)目經(jīng)理答辯(完整版)資料
- 運(yùn)動(dòng)競(jìng)賽學(xué)課件
- 重大事故隱患整改臺(tái)賬
- 2022年上海市初中畢業(yè)數(shù)學(xué)課程終結(jié)性評(píng)價(jià)指南
- DB15T 2058-2021 分梳綿羊毛標(biāo)準(zhǔn)
- 高考作文備考-議論文對(duì)比論證 課件14張
- 新華師大版七年級(jí)下冊(cè)初中數(shù)學(xué) 7.4 實(shí)踐與探索課時(shí)練(課后作業(yè)設(shè)計(jì))
- 山東省萊陽市望嵐口礦區(qū)頁巖礦
- 《普通生物學(xué)教案》word版
- 安全生產(chǎn)應(yīng)知應(yīng)會(huì)培訓(xùn)課件
評(píng)論
0/150
提交評(píng)論