-2
我需要找到一个实际的?在一系列细胞中。我正在使用此代码:查找实际?在excel vba
Dim rCell As Range
Dim rArea As Range
' set range variable = Column in the active sheet.
Set rCell = Range("g1")
Set rArea = Range("g2:g" & countusers)
For Each rCell In rArea
With rCell
Dim Qmark As Integer
If InStr(1, (rCell.Value), "~?") > 0 Then
MsgBox "Cell " & rCell.Address & "has a question mark in it"
Qmark = Qmark + 1
End If
我把〜放在问号的前面,但它不工作。 在此先感谢
'InStr'方法不需要代字符'〜',所以只要删除。如果您使用'Range.Find'方法,则只需使用波浪号 – tigeravatar