text 检查错误字符-2018-4-27

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了text 检查错误字符-2018-4-27相关的知识,希望对你有一定的参考价值。

Sub delectSymbol(ByVal control As IRibbonControl)
Dim i As Integer
Dim krt, krt1, pnx, pnx1
krt = "61549,61537,61538,61540,61541,61542,61543,61544,61546,61547,61548,61521,61553,61550,61560,61552,61555,61556,61557,61559,61561,61562,61527"
krt1 = "μ,α,β,δ,ε,φ,γ,η,?,κ,λ,Θ,θ,ν,ξ,π,σ,τ,υ,ω,ψ,ζ,Ω"
pnx = Split(krt, ",")
pnx1 = Split(krt1, ",")
For i = LBound(pnx) To UBound(pnx)
    With selection.Find
        .ClearFormatting
        .Replacement.ClearFormatting
        .Text = ChrW(pnx(i))
        .Replacement.Font.name = "Palatino Linotype"
        .Replacement.Text = pnx1(i)
        .Wrap = wdFindContinue
        
        
        .MatchWildcards = False
        Do
        .Execute
        If Not .Found Then
        Exit Do
        End If
        If .Found Then
            If InputBox("Is Symbol? Repleace?", "Symbol", "yes", 300, 300) = "yes" Then
                selection.Range.Font.name = "Palatino Linotype"
                selection.Text = pnx1(i)
                
                selection.collapse wdCollapseEnd
            End If
        End If
        Loop
    End With
Next i

With selection.Find
        .ClearFormatting
        .Replacement.ClearFormatting
        .Text = ChrW(61526)
        .Replacement.Font.name = "Palatino Linotype"
        .Replacement.Text = ChrW(962)
        .Wrap = wdFindContinue
        
        
        .MatchWildcards = False
        Do
        .Execute
        If Not .Found Then
        Exit Do
        End If
        If .Found Then
            If InputBox("Is Symbol? Repleace?", "Symbol", "yes", 300, 300) = "yes" Then
                    .Execute Replace:=wdReplaceOne
                selection.collapse wdCollapseEnd
            End If
        End If
        Loop
    End With
End Sub

以上是关于text 检查错误字符-2018-4-27的主要内容,如果未能解决你的问题,请参考以下文章

text 检查DB字符集

text 检查C中的空字符串

检查字符串数组是不是包含值,如果是,则获取其位置

如果字符串包含整数,如何调整该字符串的文本框

使用 C# 检查字符串是不是包含字符串数组中的字符串

sublime text 2 php 语法错误检查