If e.OldRange.RowSel <> e.NewRange.RowSel And ( jinzhihangjianyidong = False Or xgjinzhihangjianyidong = False ) then
试试括号。
Dim s As String = "SDFASFDSAFSA"If s.Contains("FA") And (s.Contains("E") Or s.Contains("S")) Then MessageBox.Show("A")End If