1、正则验证Dim s As String="张三,李四;王五"
Dim p As String = "(^[\u4e00-\u9fa5,]+$)" '如果包含英文名用"(^[a-zA-Z\u4e00-\u9fa5,]+$)"
Dim rgx = new System.Text.RegularExpressions.Regex(p, System.Text.RegularExpressions.RegexOptions.IgnoreCase)
If not rgx.isMatch(s) Then
msgbox("只能输入中文名字和用逗号进行分割")
End If
2、只能用字符