修复了Windows 10 Excel 2013 Build 9926查找和替换冻结错误



是否有人有更好的修复以下错误,我在Windows 10企业技术预览版Build 9926上获得Excel 2013。

在尝试运行"查找&取代的。

1.  Open a new workbook
2.  Type ‘Test’ into Cell A1
3.  Press ‘Ctrl+F’
4.  Click the ‘Replace’ tab
5.  Fill in ‘Find What’ with ‘Test’
6.  Fill in ‘Replace with’ with ‘ATest’
7.  Click ‘Replace All’
8.  Enjoy the freeze
9.  Click Ctrl+Alt+delete
10. Click ‘Task Manager’
11. Navigate to ‘Excel -> Find and Replace’
12. Right click ‘Find and Replace’ and click ‘Bring to front’
13. You now read the prompt saying ‘All done. We made 1 replacement’ (this step isn’t necessary but gives you your feedback prompt)
14. Right click ‘Find and Replace’ and click ‘End Task’
15. The task is now killed and you can go back to what you were wanting to do after the find and replace

我已经对这些步骤进行了故障排除,这样我就不必在Excel上"结束任务",如果我在查找和替换之前没有保存,这会使我失去所有的工作。

如果有人有更好的修复,请分享,否则它可能只是一个需要修复的bug。

如果使用VBA替换命令会发生什么?这不会给你提示,所以它可能是一个可行的替代品。

Cells.Replace "Test", "ATest"

也许先做一个测试,使它更健壮:

If Selection.cells.Count > 1 then
    Selection.Replace "Test", "ATest"
Else
    Cells.Replace "Test", "ATest"
End if

这样,如果你有一个选择并运行它,它就会在选择上运行,如果没有选择,它就会在工作表上运行。

在sub的上下文中,它看起来像这样:

Sub find_and_replace_fix()
    Dim sFind As String, sReplace As String
    sFind = InputBox("Find what?")
    sReplace = InputBox("replace with")
    If Selection.Cells.Count > 1 Then
        Selection.Replace what:=sFind, Replacement:=sReplace, SearchOrder:=xlByColumns, MatchCase:=True
    Else
        Cells.Replace what:=sFind, Replacement:=sReplace, SearchOrder:=xlByColumns, MatchCase:=True
    End If
End Sub

如果你愿意,你也可以更深入地检测所选的选项卡

最新更新