首页

文章

EXCEL工作表保护密码忘记了,如何撤消工作表保护?

发布网友 发布时间:2022-02-26 17:01

我来回答

3个回答

热心网友 时间:2022-02-26 18:30

 在excel中取消工作表的保护命令的方法:

1.打开excel,运行视图—宏—录制新宏—输入宏名如:aa(aa是可随意输入)。

2.停止录制,这样得到一个空宏。

3.同样视图—宏—查看宏—选aa(aa为之前新建的宏)—点击编辑按钮。

4.删除窗口中的所有字符,复制下面的内容粘贴。

Public Sub AllInternalPasswords()

' Breaks worksheet and workbook 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 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" & _

"Norman Harker and JE McGimpsey"

Const HEADER As String = "AllInternalPasswords User Message"

Const VERSION As String = DBLSPACE & "Version 1.1.1 2003-Apr-04"

Const REPBACK As String = DBLSPACE & "Please report failure " & _

"to the microsoft.public.excel.programming newsgroup."

Const ALLCLEAR As String = DBLSPACE & "The workbook should " & _

"now be free of all password protection, 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. Don't stuff up crucial formulas " & _

"or data." & DBLSPACE & "Access and use of some data " & _

"may be an offense. If in doubt, don't."

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 & 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 computer's specification." & DBLSPACE & _

"Just be patient! Make me a coffee!" & AUTHORS & VERSION

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 & _

"Now 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." & 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 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 Boolean

Application.ScreenUpdating = False

With ActiveWorkbook

WinTag = .ProtectStructure 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, vbInformation, HEADER

Else

On Error Resume Next

Do 'mmy 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 ActiveWorkbook

.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 .ProtectStructure = False And _

.ProtectWindows = False Then

PWord1 = Chr(i) & Chr(j) & Chr(k) & Chr(l) & _

Chr(m) & Chr(i1) & Chr(i2) & Chr(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 Not ShTag Then

MsgBox MSGONLYONE, vbInformation, HEADER

Exit Sub

End If

On Error Resume Next

For Each w1 In Worksheets

'Attempt clearance with PWord1

w1.Unprotect PWord1

Next w1

On Error GoTo 0

ShTag = False

For Each w1 In Worksheets

'Checks for all clear ShTag triggered to 1 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 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) & _

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...nexts

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

5.关闭编辑窗口。

6.视图—宏—查看宏,选AllInternalPasswords,点击执行,确定两次,等2分钟,再确定。密码撤销完毕。

热心网友 时间:2022-02-26 19:48

如果是要修改里面的文字数字等,只需要将文档转化为PDF格式,然后在PDF里面修改就ok了

热心网友 时间:2022-02-26 21:23

1.对Excel工作表进行保护操作后,便无法编辑工作表。
2.单击“开发工具”菜单,单击“录制宏”,在弹出的“录制新宏”对话框中修改“宏名”,最后单击“确定”按钮。
3.在“代码”区域单击“停止录制”按钮,完成宏的录制。
...火柴小女孩》《词语手册》里有很多词语的意思的,求告知 暖融融解释 领淘通淘客助手这个软件怎么样? 淘宝客必备的九大工具有哪些? 电脑里硬盘如何共享怎么实现多台电脑共用一块硬盘 两台电脑一个硬盘两台电脑是否可以同时用一个硬盘 共享电脑硬盘怎样设置局域网电脑硬盘共享 现在下载歌曲好还是不下好 故障码P033D的含义解析 切菜机多功能型切菜机 scanbox三维扫描仪 苹果13没有删除的备忘录怎么恢复? iphone备忘录永久删除怎么恢复?iphone备忘录恢复最近删除文件方法介绍... 备忘录最近删除怎么找 初一班主任工作计划 新初一班主任工作计划 359度是什么角 报个 定向乡镇卫生院 的医学好不好 酒驾缓刑节保证书怎么写 合同法律咨询免费 这款充电宝可以带上飞机吗? 倪俊卿成就及荣誉 江苏种牛站有几家? 山东宏正牧业有限公司服务承诺 吃早餐后抽血会影响体检结果吗 电脑如何设置护眼模式(台式电脑如何设置护眼模式) 电脑显示器设置护眼电脑屏幕怎么设置比较护眼 广告机是否支持分屏显示功能? 上海东丰船务有限公司怎么样? 马弗炉管厂家 CF手游体验服怎样获取资格 穿越火线体验服在哪申请资格_cf手游体验服资格申请入口链接 穿越火线体验服资格申请链接在哪-穿越火线体验服资格申请链接介绍 快手浏览量多少才能赚钱?快手靠浏览量能挣多少钱? 小麦胚芽如何吃最好 个头怎么造句 高跟鞋走路磨脚该如何处理? 除螨虫的特效药 螨虫什么药物可以除掉 网上在哪买奢侈品 二手包包闲置了怎么办 夫妻想要怀孕要提前做哪些准备 手机图片如何投屏到电视上去 手机图片投屏到电视上去的方法 分区助手无法压缩卷怎么处理? 广州北斗公司有哪些 在文件夹里.把cfg文件删掉.电影还可以看么? 办理骑士卡要钱吗? 一千个伤心的理由吉他谱前奏怎么弹出 一千个伤心的理由吉他谱 去中国逛夜市,必买的小吃有哪些? 上海香肠的配料秘方有哪些? excel中的文件保护密码忘记了怎么办 设置的工作表保护密码忘记了怎么办 EXCEL(2007)工作表保护密码忘记了,如何撤消工作表保护? 手机qq怎么查看好友撤回的图片??是图片哦 Excel2003如何取消工作表保护?密码忘记了。 EXCEL工作表保护密码忘记了,如何撤消工作表保护?急~~~ 工作表撤销保护密码忘记了怎么办啊,工具里面的宏不管用 EXCEL工作表保护密码忘记了,如何撤消工作表保护?急~~~~谁能帮我破解下 pdf档怎么转换成ppt档 WPS表格被保护忘记密码怎么撤销? 工作表保护密码忘了怎么办 excel 如何撤销工作薄保护,忘记密码了? excel表格中忘了撤销工作表保护密码怎么办 忘记了工作表的保护密码该如何解决? 忘记WPS工作表当中的撤消密码怎么办? 想问一下如何撤销工作表保护,忘记密码了 wps表格工作表被保护 但是密码忘记了 怎么撤销保护呢? wps表格工作表被保护 但是密码忘记了 怎么撤销保护呢 wps中excel表格密码忘记了,怎么撤销工作表保护? excel表格忘了密码怎么撤销工作保护 如何一次性删除一个WORD文档中的所有批注? word怎么批量删除批注 如何批量删除word批注 word2010中怎么删除去掉取消全部的批注,批改 word如何删除所有批注只保留最终版 word修改的时候有批注如何批量删除 word里如何删除批注 请问excel中切换不同工作表的快捷键(能在左边键盘中操作,不是ctrl+pageup等) 怎样一次性删除所有批注? word里的批注怎么删除 word如何删掉批注 Word2010删除全部批注 word里面批注怎么删除 关于word中删除所有批注的方法正确的是 在word中一次删除所以批注该怎么操作呢 word里面按批注的内容修改后怎么删除批注 如何批量删除word文档中的批注 word中怎么删除批注 怎么样在Word2007方框中打钩和打叉 win10怎么查看电脑硬件配置
声明声明:本网页内容为用户发布,旨在传播知识,不代表本网认同其观点,若有侵权等问题请及时与本网联系,我们将在第一时间删除处理。E-MAIL:11247931@qq.com